Skip to Content
Outbound calls

Cancel an outbound job

Permissioncalls:place-outboundRetriesIdempotency-Key requiredAuthentication
POST
/outbound-jobs/{id}/cancel

Cancels scheduled, queued, claimed, reserving, or retry-wait jobs. Repeating cancellation is a 200 no-op with changed=false, preserves the current ETag, and records an outbound_job.cancel.noop audit event. Once dialing may have begun, returns 409 and includes the linked call ID when known; end that call through the calls API instead.

Authorization

bearerAuth
headerAuthorizationBearer <token>

Use a Voice API key or connected-app OAuth access token. Authentication.

Path Parameters

id*string
Formatuuid

Header Parameters

If-Match?string

Optional strong ETag (or *) from a prior response. A stale tag returns 412 without changing the resource.

Idempotency-Key*string

Required. Reuse the same key to retry this write safely. Retries and idempotency.

Match^[A-Za-z0-9!#$%&'*+.^_`|~-]+$
Length1 <= length <= 255

Request Body

application/json
  1. body
reason?string

Optional audit reason. Leading/trailing whitespace is removed and control characters are rejected.

Length8 <= length <= 500

Response Body

Job is canceled; changed distinguishes a transition from an idempotent no-op.

application/json
  1. response
id*string
Formatuuid
status*string
changed*boolean
updated_at*string
Formatdate-time
Example Request
curl -X POST 'https://api.kejue.co/v1/outbound-jobs/497f6eca-6276-4993-bfeb-53cbbbba6f08/cancel' \  -H 'Idempotency-Key: string' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "status": "canceled",  "changed": true,  "updated_at": "2019-08-24T14:15:22Z"}