Docs

Start here

Stop a job that is still running

DELETE/v1/jobs/{id}on https://api.auray.ai/v1

Settles what it was worth; does not delete the row.

Settles what it was worth; does not delete the row. Photo refunds in full, music and video bill the fraction made, 3D keeps the completed stages' shares. Cancelling something already finished is 200 with cancelled:false, not an error. A job that is charged but has no provider_job_id yet answers 200 with cancelled:true and settled:false: the stop is recorded on it and carried out as soon as it has one, or once it can no longer get one — refund included, and in full for a job that finished before the stop could reach it, whose output is withheld; poll it to see it settle. 3D can answer 409 cancel_refused when it cannot stop the job. A catalogue model that cannot be stopped once it starts answers 409 cancel_not_offered — it keeps running and keeps being charged — and a product with no cancel at all (chat) answers 400 cancel_unsupported.

#Authentication

Authorization: Bearer auray_sk_… — A scope that may submit the job's model: the kind it makes (image:write, video:write, …) or the older product name (photo:write, auray-ai-video:write, external:write).

#Request

#Path parameters

NameTypeRequiredDescription
idstringyes

#Example request

curl -X DELETE https://api.auray.ai/v1/jobs/photo_docs-mtpb1vnh \
  -H "Authorization: Bearer $AURAY_API_KEY"

#Responses

#200 OK

OK

FieldTypeRequiredDefaultDescription
idstringno—
statusstringno—Five words, whatever the product. Our internals disagree; you never see that. One of "queued", "running", "succeeded", "failed", "cancelled".
cancelledbooleanno—
settledbooleanno—
credits_chargedintegerno—What the job cost, after the cancel's refund — the ledger's net. Null, with settled_unknown: true, when the ledger could not be read; the job read answers it once it can. May be null.
credits_reservedintegerno—What was taken when the job was charged. May be null.
settled_unknownbooleanno—Present, and true, when the cancel happened and its figures could not be read.

Headers:

HeaderDescription
RateLimit-LimitBurst capacity.
RateLimit-Remaining
RateLimit-ResetSeconds until refill.
X-RateLimit-Limit
X-RateLimit-Remaining
X-RateLimit-ResetUnix seconds. The X- spelling is what client libraries read.
X-Request-Id

#400 Bad Request

#401 Unauthorized

#403 Forbidden

#404 Not Found

#409 Conflict

#410 Gone

#429 Too Many Requests

#500 Internal Server Error

settle_failed — the cancel reached the service, but the outcome could not be recorded. Read the job again in a moment. Or job_read_failed, when the job could not be looked up at all: that one is not a statement that the job is gone, and the render is still running and still charged.

The error body: error, message, docs (the entry that explains it) and request_id.

#502 Bad Gateway

#503 Service Unavailable

#Status codes

StatusMeaning
200OK
400Bad Request
401Unauthorized
403Forbidden
404Not Found
409Conflict
410Gone
429Too Many Requests
500settle_failed — the cancel reached the service, but the outcome could not be recorded.
502Bad Gateway
503Service Unavailable

Every refusal names its code, and every code is explained at Errors.

Start typing to search every page of the documentation.

Up arrow Down arrow to moveEnter to openEscape to close