Errors
Error response
Section titled “Error response”Most errors return this JSON body:
{ "request_id": "req_…", "code": "JOB_RECIPE_NOT_FOUND", "message": "The requested recipe is not available.", "retryable": false, "field_details": {}, "documentation_url": "https://docs.originalpictures.com/api/errors"}| Field | Description |
|---|---|
request_id |
Unique request identifier. Include it in every support request. |
code |
Machine-readable reason code. See Reason codes. |
message |
Human-readable explanation. Do not parse it. |
retryable |
Whether repeating the same request can succeed. |
field_details |
Per-field validation messages, when relevant. |
documentation_url |
Link to this page. |
detail_code |
Optional. A narrower stable reason under the same code. |
job_reference |
Optional. The related job, present only when the error concerns one. |
Branch on code and retryable, never on message. Responses never include stack traces or
storage identifiers.
Request-shape validation failures return 422 with this body, and field_details maps each
offending field to its message (an object, not a list). A missing required Idempotency-Key is
one of them: 422 with the operation’s family code (for example JOB_POLICY_REJECTED on
POST /v1/sign). Authentication and scope failures (401, 403) and some routing failures
return a minimal {"detail": "…"} body without a request_id. Every reason code is listed in
Reason codes.
Status codes
Section titled “Status codes”| Status | Meaning |
|---|---|
| 401 | Missing, invalid, or revoked credential. The body never says which. |
| 402 | Billing quota or account state prevents the operation. |
| 403 | The key lacks the operation’s scope, the operation is denied by default, or the key’s IP allowlist excludes this client. |
| 404 | The resource does not exist in your tenant. |
| 409 | Conflict, for example an Idempotency-Key reused with a different payload. |
| 410 | The resource has expired, for example an upload session. |
| 422 | The request is malformed. |
| 429 | Too many requests: the key’s own rate limit, or an operation that enforces a rate. Wait for Retry-After. |
| 503 | A required dependency is temporarily unavailable. Retry with backoff. |
API key restriction codes
Section titled “API key restriction codes”A key can carry its own rate limit and IP allowlist (see Authentication). Three reason codes belong to them:
| Code | Status | Meaning |
|---|---|---|
API_KEY_RATE_LIMITED |
429 | The key’s own rate limit was exceeded. Retryable after Retry-After seconds. The refused request used no capacity. |
API_KEY_IP_NOT_ALLOWED |
403 | The key is limited to client networks and this request came from outside them, or from an address the API could not determine. |
API_KEY_IP_ALLOWLIST_UNAVAILABLE |
409 | This deployment cannot yet trust the client address, so it does not accept an IP allowlist. A rate limit can still be set. |
A 429 API_KEY_RATE_LIMITED response also carries RateLimit-Policy, for example
"per-key";q=60;w=60: q requests per w seconds.
Concurrent writes
Section titled “Concurrent writes”Writes for one account are applied one at a time, so the account’s history stays in a single
order. The API queues a burst of parallel requests, such as many upload completions at once,
and retries them for you for a few seconds. If a write still can’t be admitted, the response is
503 with TENANT_WRITE_CONTENDED, retryable: true and a Retry-After header. Nothing was
changed, so repeat the same request with the same Idempotency-Key after Retry-After
seconds. This code is never a reason to change the request.
Open list traversals
Section titled “Open list traversals”Each first page of GET /v1/assets, /v1/jobs, /v1/receipts or /v1/verifications pins a
consistent view of the account, which its next_cursor continues for up to 15 minutes. An
account can hold a limited number of these views at once, and a new one is needed whenever the
account has changed since the last. If a busy account reaches the limit, a first page answers
503 with HISTORY_QUERY_INVALID, retryable: true and a Retry-After header giving the
seconds until the oldest view expires. Retry after that, or keep paging with a cursor you
already have: continuing a traversal is never refused for this reason.
Retries
Section titled “Retries”- Retry only when
retryableistrue, or on429and503. When the response has aRetry-Afterheader, wait at least that many seconds; otherwise use exponential backoff with jitter. - Send the same
Idempotency-Keyon a retry so the API does not create duplicate work. - A timeout on your side does not cancel a durable job. Poll the job instead of resubmitting it.
SDK errors
Section titled “SDK errors”The SDKs raise typed errors that carry the same code, request_id, and retryable values.
Examples are AuthenticationError, PermissionDeniedError, NotFoundError, ConflictError,
RateLimitError, and ServiceUnavailableError. See the Python and
TypeScript pages.