API reference
Cancel a job
Stop a job before generation starts.
POST /v1/jobs/{id}/cancel
Host https://api.open.sume.com · Auth API key
Cancels a job that has not started generating. The reserved price is refunded. Once the model has started, the job can no longer be canceled: the status response says whether it still can (cancelable, cancel_url).
Request
Headers
| Header | Type | Required | Description |
|---|---|---|---|
Authorization | string | Yes | Bearer <key>. Or send x-api-key. |
Path
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | The job id (job_...). |
Example
Cancel a job
POST /v1/jobs/{id}/cancel
Required
Response
200 OK
The canceled job, with status: "canceled". A job that has already started answers 409 job_not_cancelable:
Errors
| Status | code | When |
|---|---|---|
| 401 | unauthorized | No key, or the key is wrong or revoked. |
| 404 | not_found | No job with that id in your workspace. |
| 409 | job_not_cancelable | Generation has started, or the job has already ended. |
| 429 | rate_limited | Too many requests for your key in this window. |