jobs

Job settled

Sent to your webhook_url once a job settles, whether it succeeded or failed.

Answer 2xx as soon as you have the body, and do the work afterwards. A delivery that times out, or that is answered with a 5xx or a 429, is retried with the delay doubling between attempts; any other 4xx is read as a refusal and not retried. A redirect is not followed — register the address you want called.

Deliveries are at-least-once: an endpoint that is slow enough to time out is retried while it is still working on the first one. Make your handler idempotent on id.

postWebhookjob.settled

Headers

CV-Timestampstring required

When this delivery was signed, in whole seconds since the Unix epoch, written in digits only. Part of the signed material, and worth rejecting when it is old.

CV-Signaturestring

sha256= and the hex HMAC-SHA256 of <CV-Timestamp>.<body> under your signing secret. Absent when no secret is in place for your endpoint.

Payload

idstring required
custom_idstring nullable

Your own identifier for the job, if you sent one.

modelstring nullable

The model this job was sent to.

status'queued' | 'running' | 'succeeded' | 'failed' required
flaggedboolean nullable

Whether an automated check thought this job's images may fall outside what the service allows: the part of your image the job worked on (all of it, unless you named a region), and for some jobs the one that came back. null means they were not all checked.

errorstring nullable

Why a failed job failed, in words meant for a person.

error_codestring nullable

The same fact as error, as a stable identifier to branch on. New codes appear as new things become worth telling apart, so treat an unfamiliar one as a failure you have no special handling for rather than as an error in itself. A failed job is never charged, whatever the code; inference_failed is the one worth singling out, because it means the fault was ours and the same request is worth retrying.

communityboolean

Whether the job runs on the community queue, which runs on shared, free capacity and can wait longer at busy times. Explains a long wait that is not a fault.

creditsinteger nullable

What this job was billed. A job is charged when it succeeds — a still at the model's image price, a video by its length — so this reads 0 until then, and stays 0 for a job that fails.

created_atstring date-time nullable

When the job was submitted. ISO-8601, UTC.

finished_atstring date-time nullable

When the job settled. ISO-8601, UTC. Not stated while a job is still queued or running.

thumbnail_urlstring nullable

A temporary link to a small preview of the job's picture — the result, or the image the model worked from when the job produced no file — for showing a list of jobs without fetching each one whole. Absent until the job succeeds, where no preview could be made, and once the job's pictures are deleted.

keptboolean

Whether this result was asked to outlive the ordinary retention schedule.

eta_secondsnumber nullable

Rough seconds until the job finishes — the wait for capacity plus the time running. Not stated once a job has settled, so a callback never carries one.

Response

Successful Response

unknown required

Changes

Webhooks have no change history: a webhook is keyed by its event name rather than a path and method, so no recorded change can name it.