Use this call to determine the value of the current period in Anaplan.
This helps an integration determine which time period the model currently treats as “current” before loading data, running forecasts, or applying time-based logic.
If the current period is not set in Anaplan, this call returns empty strings for the periodText and lastDay values of the currentPeriod.
Notes:
- To use this call, you must be a Workspace Administrator.
Method and endpoint
/workspaces/{workspaceId}/models/{modelId}/currentPeriod
Parameters
| Parameter | Details |
{workspaceId} |
|
{modelId} |
|
Curl example
curl -X GET 'https://api.anaplan.com/2/0/workspaces/{workspaceId}/models/{modelId}/currentPeriod' \
-H 'Accept: application/json' \
-H 'Authorization: AnaplanAuthToken {anaplan_auth_token}'
Response
Response header
Content-Type: application/json
Response 200 body
{
"meta" : {
"schema" : "https://api.anaplan.com/2/0/objects/currentPeriod"
},
"status" : {
"code" : 200,
"message" : "Success"
},
"currentPeriod" : {
"periodText" : "May 20",
"lastDay" : "2020-05-31",
"calendarType" : "Calendar Months/Quarters/Years"
}
}