Operations

Cancel an operation

Changed on

Requests cancellation of an operation. A pending operation is cancelled immediately. A running operation is flagged for cancellation; the worker observes the flag at its next checkpoint. Operations that have already reached a terminal state cannot be cancelled. Cancellation does not roll back work that has already completed.

post/operations/{id}/cancel

Request

  • Base URL: https://api.cavuno.com/v1
  • URL: https://api.cavuno.com/v1/operations/{id}/cancel
  • Auth: HTTP bearer

Path parameters

idstring required

Unique identifier for the operation.

Response

Successful response. The returned operation reflects cancelRequested: true; the worker observes the flag at its next checkpoint.

idstring required

Unique identifier for the object.

object'operation' required

String representing the object's type. Objects of the same type share the same value.

kind'domains.verify' | 'imports.parse' | 'imports.confirm' | 'subscribers.export' | 'subscribers.import' | 'custom_objects.records_import' | 'exports.generate' | 'candidates.remove' | 'employers.remove' required

Operation kind, identifying which workflow the operation runs.

state'pending' | 'running' | 'succeeded' | 'failed' | 'cancelled' required

Current state of the operation.

createdAtstring required

Time at which the operation was created. ISO 8601 datetime.

updatedAtstring required

Time at which the operation was last updated. ISO 8601 datetime.

completedAtstring nullable required

Time at which the operation reached a terminal state, or null if it has not yet completed. ISO 8601 datetime.

cancelRequestedboolean required

Whether cancellation of the operation has been requested.

Changes