Get an async task
GET /async_tasks/{uuid}
/async_tasks/{uuid}Returns the state of one background task: its status, how many items were processed or failed, the progress and, if it failed, the error. For exports it also gives a temporary address (valid 15 minutes) to download the file.
When to use: After calling an asynchronous operation (those whose operationId starts with async_task_): it returns a task at once, not the result. Repeat this call every few seconds until status is completed or failed; then use result_meta or result_file_url. Do not assume the work is done before that.
When not to use: To follow a batch of API calls use get_batch_operation.
Permissions: Requires the viewer role or higher, or the marketing.audiences.read capability.
Value for the X-Auth-Token header parameter.
In: header
Path Parameters
UUID of the task: the uuid returned by the operation that started it, or found with list_async_tasks.
Response Body
application/problem+json
application/problem+json
application/problem+json
curl -X GET "https://api.easymailing.com/async_tasks/6b1e4d90-2a73-4c58-8f0b-e5d9a3c71f24" \ -H "X-Auth-Token: YOUR_API_KEY"{ "uuid": "095be615-a8ad-4c33-8e9c-c7612fbf6c9f", "type": "string", "status": "pending", "total": 0, "processed": 0, "errored": 0, "progress": 0.1, "error_message": "string", "result_meta": {}, "result_file": "string", "result_file_url": "http://example.com", "started_at": "string", "finished_at": "string", "created_at": "string"}