Saltar al contenido principal

Documentación

Errores

Las guías detalladas y la referencia de la API están solo en inglés.

Error format

Every error uses the same JSON envelope:

{
  "error": {
    "code": "plan_quota_exhausted",
    "message": "Studio daily quota used up",
    "plan": "studio",
    "details": { "kind": "image", "limit": 45, "used": 45, "resets_at": "2026-10-04T00:00:00Z" }
  }
}
  • code is stable and meant for your code. message is for people and may change.
  • plan is "studio", "credits" or null. Every error about a plan group names the group.
  • details depends on the code; it is always an object.

Error codes

HTTPCodeMeaningDetails
400plan_requiredplan is missing
401unauthorizedMissing, malformed or revoked API key
402no_active_planNo active Studio plan (plan: "studio" only)
402plan_quota_exhaustedThe Studio daily quota for this kind is used upkind, limit, used, resets_at
402insufficient_creditsNot enough credits (plan: "credits")required, available
403bannedThe account is suspended
403first_payment_requiredAPI keys and webhooks unlock after the first USDT payment
403terms_not_acceptedYou must accept the current terms in the web appcurrent_version
404not_foundThe job does not exist, is not yours, or the content URL is not valid
409idempotency_conflictThe Idempotency-Key was used with a different body, or a duplicate request is still running
409not_cancellableThe job already runs and cannot be cancelled
410result_expiredThe download window of the result has endedexpired_at
413invalid_parametersThe request body is too largemax_bytes
422invalid_parametersA parameter is wrongfield, reason
422model_not_in_planThe model is not included in Studio
422content_policy_violationThe prompt was blocked by the content policy; nothing is charged
429rate_limitedToo many requests or downloadsscope: key, plan, auth, ip, bandwidth, job; for the last two limit_bytes
429queue_fullYou have 20 jobs waitingmax_pending
502result_unavailableThe result cannot be retrieved right nowgeneration_id
503model_unavailableThe model is under maintenance or paused
504generation_pendingThe OpenAI compatible endpoint timed out waiting for the imagegeneration_id
500internalSomething went wrong on our side

details.reason of invalid_parameters can be required, too_long, unsupported, not_allowed, too_few, too_many, max_keys, max_endpoints, invalid_range, multi_range_not_supported, among others.

A job that starts and then fails is reported on the job itself: status: "failed", error_code and error (with a safe reason such as timeout or source_failed). Failed jobs are refunded to the group that was charged.

Retries

  • 429 and 5xx are safe to retry with the same Idempotency-Key; wait for Retry-After seconds when the header is present.
  • 4xx other than 429 will not succeed on a retry without a change on your side.