Supervideo API docs

Errors

Every error, from every endpoint, has one shape:

{
  "error": {
    "code": "insufficient_credits",
    "type": "insufficient_quota",
    "message": "Your balance is too low for this request.",
    "metadata": {"required_usd": 0.5, "available_usd": 0.12}
  }
}

Every answer also has an X-Request-Id header. Quote it when you ask us for help.

Retrying

Error codes

HTTPcode / typeWhat to do
400idempotency_key_required
invalid_request_error
Send an Idempotency-Key header on every create: a new UUID for each new request, the same one when you retry it.
400invalid_batch
invalid_request_error
The batch body is wrong: one or more requests are not valid for their url. metadata.details lists each by index and custom_id, with its own code and message. Nothing was created.
400invalid_input_url
invalid_request_error
An input reference is not a file id you own, an upload:// reference, or a public https URL. Upload the file first, or use a URL that is reachable from the internet.
400invalid_request
invalid_request_error
A field is missing, has the wrong type or is not allowed here. param names it and message says what is wrong. Fix the request; retrying it unchanged fails again.
400invalid_seconds
invalid_request_error
seconds is outside the model's min_seconds..max_seconds. metadata.allowed has the range.
400invalid_size
invalid_request_error
The size, resolution or aspect_ratio is not offered for this model. metadata lists what is allowed. See the model's resolutions, size_multiple and max_side.
400unsupported_mode
invalid_request_error
The model cannot do what your inputs ask for (for example a first frame sent to a text-to-video model). metadata.allowed lists its modes. Pick another model or change the inputs.
401unauthorized
authentication_error
The API key is missing, mistyped, revoked or expired. Send Authorization: Bearer <your API key> with a key from the console. Do not retry with the same key.
402insufficient_credits
insufficient_quota
The wallet cannot cover the most this job can cost. metadata.required_usd and metadata.available_usd say by how much. Add credit, then retry. Nothing was queued.
403key_scope_denied
permission_error
This key may not use the media API. Create a key with media access in the console.
403model_not_available_in_region
permission_error
The model's licence does not allow it for your account's country or data region. Use another model.
403team_keys_not_supported
permission_error
This kind of key cannot be used here. Use a personal API key from the console.
404model_not_found
not_found_error
No model with that id is available to this key. List what you can use with GET /v1/models.
404not_found
not_found_error
No such object, or it belongs to another account. Check the id.
405method_not_allowed
invalid_request_error
The path exists but not with this HTTP method. Check the endpoint reference.
409cannot_cancel_in_progress
invalid_request_error
The job is already generating and will run to the end. It is billed when it completes.
409data_region_locked
conflict_error
The account's data region is already set and cannot change. Leave data_region out, or send the account's region.
409file_in_use
conflict_error
An unfinished job still uses this file. Delete it after the job ends.
409idempotency_conflict
conflict_error
This Idempotency-Key was already used with a different body. Use a new key for a new request.
409idempotency_in_progress
conflict_error
The first request with this key is still being created. Wait Retry-After seconds and send the same request again with the same key.
409job_not_finished
conflict_error
Only a finished job can be deleted. Cancel it first if it is still queued, or wait for it to end.
409media_not_ready
conflict_error
The job has not finished yet. Wait for status: completed, then download.
409upload_incomplete
conflict_error
The upload's bytes have not all arrived. PUT the file to upload_url, then call /complete.
410data_removed
gone_error
The media has passed its retention period, or the job was deleted. It cannot be downloaded any more.
413request_too_large
invalid_request_error
The body is larger than allowed (1 MB for a create, 8 MB for a batch, 20 MB for POST /v1/files). Send inputs as file ids or URLs, not inline, and use /v1/uploads for large files.
422content_rejected
content_policy_error
Content screening refused the prompt or an input. Change it. You were not charged.
422file_rejected
invalid_request_error
The file failed the checks: empty, larger than declared, or its contents are not the declared content_type. message says which. Upload a correct file.
429queue_full
rate_limit_error
The queue for this model is full right now. Retry after Retry-After seconds, or use a batch.
429rate_limited
rate_limit_error
Too many requests for this key. Wait Retry-After seconds. See Rate limits.
429too_many_jobs
rate_limit_error
The key has the most unfinished jobs it may have at once. Wait for some to finish, or use a batch.
429too_many_streams
rate_limit_error
Too many open long-polls and event streams for this key. Close some, or poll with poll_after_ms.
500internal_error
server_error
Something broke on our side. Retry with the same Idempotency-Key; if it keeps failing, send us the X-Request-Id.
502upstream_error
server_error
The generation service failed to answer, or (for an image created with Prefer: wait) the image failed. Retry with the same Idempotency-Key. A failed job is not charged.
503capacity_unavailable
server_error
Busy right now, or a GPU could not start the job within your max_wait_s. Nothing was queued or charged. Retry after Retry-After seconds.
503model_not_ready
server_error
The model exists but cannot take jobs right now (no price or no GPUs yet). Retry after Retry-After, or use another model; GET /v1/models shows is_ready.
503not_configured
server_error
This part of the service is not switched on yet (for example card top-ups). Try again later.
504upstream_timeout
server_error
The generation service did not answer in time. Retry with the same Idempotency-Key.

Why a job failed

A job that ends failed has an error with one of these codes. A failed job costs nothing. A failure inside a GPU is retried on another GPU before a job is ever marked failed, so these are mostly about the input.

error.codeMeaning
queue_timeoutNo GPU became available in time. You were not charged.
invalid_inputAn input file could not be used: it is damaged or not a supported format. Fix the input and send the request again. You were not charged.
too_largeThis size or length is not supported for this model. Use a smaller size or a shorter clip. You were not charged.
input_fetch_failedAn input file could not be downloaded.
content_rejectedThe request was refused by content screening.
cancelled_by_deadlineThe job was cancelled because its deadline passed.
queue_fullThe queue was full, so this request was not started. You were not charged.
generation_failedThe generation failed. You were not charged.