Public preview: This API is in public preview. Endpoints, schemas, and limits may change before general availability.

Errors

HTTP status codes, error payload shapes, and which errors are worth retrying.

EU GPT returns conventional HTTP status codes with a small JSON body. This page lists the codes, the payload shapes, and which failures are worth retrying.

Payload shapes#

Most errors carry a detail field, either a plain message or an object with a machine-readable error code:

{ "detail": "Conversation not found" }
{ "detail": { "error": "model_not_found", "message": "Unknown model 'gpt-4o'. GET /v1/models lists the models you can use, or use 'auto'." } }

Two kinds of errors look different:

  • Authentication errors (401) use an error object, like OpenAI:

    { "error": { "message": "Invalid, expired, or revoked API key", "type": "authentication_error" } }
  • Validation errors (422) list what is wrong with the request:

    {
      "detail": [
        { "type": "missing", "loc": ["body", "input"], "msg": "Field required", "input": { "model": "auto" } }
      ]
    }

A few 5xx responses from the load balancer have a plain text body. Always check the HTTP status first, then read detail or error if present, and use detail.error when it is there.

Status codes#

400 Bad Request#

The request is well-formed JSON but cannot be answered:

  • The question is empty: { "detail": "Input message is required" }. Every request needs a text part, also when you attach files.
  • model names a model EU GPT does not know: detail.error is model_not_found. GET /v1/models lists the valid ids.

Do not retry without changes: fix the request first.

401 Unauthorized#

Missing, malformed, unknown, expired, or revoked API key. Check:

  • The Authorization header is present and has the form Bearer eugpt_….
  • The key has not been revoked on the API Keys page.

Do not retry until you have fixed credentials.

402 Payment Required#

The prepaid balance that pays for API usage cannot cover the request. detail.error says why:

{ "detail": { "error": "wallet_insufficient_funds", "message": "No prepaid balance for API usage. Add credit to your wallet to use the API." } }
detail.errorWhat to do
wallet_insufficient_fundsThe balance is too low, or there is none yet: add credit.
auto_topup_failedAuto top-up is off because the card was declined or a payment was reversed: link a card again.
auto_topup_cap_reachedAuto top-up reached its monthly limit: raise the limit or add credit.

Not worth retrying until the balance is topped up. See Usage limits & billing.

403 Forbidden#

The key is valid but the request is not allowed: project_id refers to an agent (project) you are not a member of.

{ "detail": "Not a member of this project" }

Retry only after fixing membership.

404 Not Found#

The referenced resource does not exist for this user: Conversation not found, Project not found, or a file id on the Files API. Another user’s conversation or file also returns 404, so the API does not reveal whether it exists.

Do not retry: the resource is not coming back. An endpoint that EU GPT does not offer, such as /v1/chat/completions, also returns 404.

413 Payload Too Large#

A file upload larger than 10 MB. See the Files API reference.

422 Unprocessable Entity#

The request does not match the schema: input is missing, a UUID is malformed, max_output_tokens is not a positive integer, or a content part has an unknown type. The detail list says which field is wrong. Fix the request; do not retry as is.

429 Too Many Requests#

(Planned.) Your subscription plan’s usage limits do not apply to API requests; the prepaid balance is the limit. Once keys can have their own limits, 429 will appear with rate_limit_exceeded (worth retrying after a short pause) or monthly_quota_exceeded (not worth retrying until next month or until the key’s cap is raised).

500 Internal Server Error#

An unexpected failure in EU GPT, for example { "detail": "Response generation failed" } for a non-streaming request. May be transient.

Retry once or twice with exponential backoff. If it persists, the issue is on our side: check the status page (when available) and reach out.

503 Service Unavailable#

detail.error says which:

  • model_unavailable: no model is available through the API right now. Retry with backoff.
  • pricing_unavailable: the model you named has no price for your account right now, so EU GPT will not run it. Use another model or auto, and contact us if it persists.

502 / 503 / 504#

Returned by the load balancer when the service is overloaded or restarting, or when a request runs longer than 10 minutes. Treat them as transient: retry with exponential backoff.

Errors in the stream#

If the failure happens after the response has started streaming, the HTTP status is still 200, and the stream contains an error event:

event: message
data: {"type":"error","sequence_number":17,"code":"model_error","message":"No response received from model"}

Always check for an error event: do not assume success just because the stream opened, and treat the response as failed even if response.completed follows the error. The codes:

  • model_error: the model failed or did not answer. Retry.
  • chain_error: an internal error in EU GPT. Retry once.
  • stream_error: the stream itself broke down (sent with an event: error line). Retry once.

A non-streaming request cannot report these: when the model fails mid-way, you get a 200 with an empty or partial output_text. If that matters to you, stream.

Idempotency#

The endpoint does not yet honour Idempotency-Key. A retried request generates a fresh response. For interactive use this is rarely a problem; for batch jobs, dedupe on your side using a job identifier and only retry on documented retriable codes.