Cancel an operation
/operations/{operation_id}Requests cancellation of an operation. Set cancellation_requested to true and optionally provide a reason.
Cancellation is cooperative: a queued operation is canceled immediately, while a running operation stops between items. Items that have already been processed are not reverted.
Setting cancellation_requested to false has no effect; a cancellation request cannot be withdrawn. Operations that have already reached a terminal status return operation_not_cancelable.
Autonomous mode: the API credential secret, sent as a bearer token. Credential secrets are identified by a fixed prefix.
In: header
Path Parameters
Header Parameters
Client-generated key that makes the request safe to retry. Must be 1 to 128 characters from [A-Za-z0-9._:-]. Optional on this operation; when sent, a malformed key returns idempotency_key_invalid, and repeating the request with the same key and the same body returns the stored result with Idempotent-Replayed: true.
Optional client-generated identifier of the request, up to 64 characters from [A-Za-z0-9._-]. Echoed back in the response and recorded in the request log; it never replaces the server-generated X-Request-Id.
length <= 64Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/operations/string" \ -H "Content-Type: application/json" \ -d '{ "cancellation_requested": true }'{ "data": { "attempt": { "number": 0, "status": "running" }, "cancellation_requested": true, "created_at": "2019-08-24T14:15:22Z", "error": {}, "expires_at": "2019-08-24T14:15:22Z", "finished_at": "2019-08-24T14:15:22Z", "id": "string", "items_url": "string", "object": "operation", "progress": { "done": 0, "failed": 0, "total": 0 }, "result_url": "string", "started_at": "2019-08-24T14:15:22Z", "status": "queued", "type": "string" }}Retrieve an operation GET
Retrieves the status and progress of an asynchronous operation. Poll this endpoint until the operation reaches a terminal status: `succeeded`, `partially_succeeded`, `failed`, or `canceled`.
List operation attempts GET
Lists the execution attempts of an operation, most recent first, using cursor-based pagination.