Cancel pending (and optionally running) migration jobs for an entity
Operational queue cleanup. Sets status='cancelled' on every pending
migration job for the entity, and (optionally) every running job. A
cancelled job is distinct from a failed job: monitoring should not
treat it as an error, and the audit reason is recorded in the job’s
errors[] JSONB so the cancellation context is preserved.
Common use cases:
- The entity is being abandoned for a fresh entity, so the queue is contaminated.
- A buggy bulk-submit needs to be drained before a clean re-run.
- The runner is being redeployed and in-flight jobs should not be claimed mid-update.
Body parameters.
reason(optional string) — audit note stored in each cancelled job’serrorsarray. Defaults to"admin_cancelled".include_running(optional boolean) — also cancelrunningjobs. Defaultfalse. Risky for live runs (cancels in-flight work); use only when you’ve confirmed nothing meaningful is in flight.
Scope: migration:write.
Authorizations
API key issued per entity via Settings > Developers > API Keys.
Each key carries scopes (e.g. orders:read, products:write).
Bearer token format: Authorization: Bearer ark_live_ent_Test keys use ark_test_ent_. Both are issued per entity
via Settings > Developers > API Keys.
Path Parameters
Body
Response
Cancel result with the list of cancelled job IDs

