Use this endpoint to get the status of a specific export task.
Get the status of an export task
Notes:
- As best practice, we recommend you check the status of an ongoing export action no more than once every five seconds. For long-running exports, it is suggested to check at even longer intervals.
- You can cancel an ongoing monitoring task if you make the same call using the
DELETEverb instead of theGETone.
In the response:
currentStepis the task associated with the specifiedtaskID.taskStateis the status of that export task.progressis a double that is typically 1.0.resultis a JSON object that indicates the object ID, and whether the task succeeded.taskIdis the ID that you specified in the request.
Here is a list of each possible taskState:
| Status | Description |
| NOT_STARTED | The task is scheduled to run, but has not started yet. |
| IN_PROGRESS | The task is currently running. |
| COMPLETE | The task has finished running whether successful or not. |
| CANCELLING | The task is currently being canceled. Cancellation is not yet complete. |
| CANCELLED | The task has been canceled and the changes have been rolled back. |
If failures occur during the export task details contains a JSON array that contains debug information |
Method and endpoint
/workspaces/{workspaceId}/models/{modelId}/exports/{exportId}/tasks/{taskId}
Parameters
| Parameter | Description |
workspaceId |
|
modelId |
|
exportId |
|
taskId |
|
Curl Example
curl -X GET \
https://api.anaplan.com/2/0/workspaces/{workspaceId}/models/{modelId}/exports/{exportId}/tasks/{taskId} \
-H 'authorization: AnaplanAuthToken {anaplan_auth_token}' \
-H 'Content-Type:application/json'
Response
Response 200 (application/json)
{
"meta":{
"schema":"https://api.anaplan.com//2/0/models/736367E9DB484E3AB3A50C3704FD33ED/objects/task"
},
"status":{
"code":200,
"message":"Success"
},
"task":{
"type":"taskInformation",
"taskId":"BFEC582EBD4146068FE4061831C8F0F0",
"currentStep":"Complete.",
"progress":1,
"result":{
"failureDumpAvailable":false,
"objectId":"116000000002",
"successful":true
},
"taskState":"COMPLETE"
}
}