Skip to main content

Errors

Standard Compute uses standard HTTP status codes. Error bodies follow the format of the API you called.

Error format​

On OpenAI endpoints:

{
"error": {
"message": "Your monthly compute budget is used up. ...",
"type": "insufficient_quota",
"code": "budget_exhausted"
}
}

On the Messages API:

{
"type": "error",
"error": { "type": "rate_limit_error", "message": "..." }
}

Status codes​

StatusCodeMeaningWhat to do
400model_not_foundThe model ID doesn't exist.Use standardcompute or an ID from /v1/models.
400invalid_modelmodel is null, empty or not a string.Send a model ID, or omit the field.
400unsupported_model_inputImages were sent to a text-only model.Use a vision model or standardcompute.
400unsupported_parameterA parameter isn't supported, such as previous_response_id.See the endpoint's page.
401The API key is missing or invalid.Check the Authorization header.
402budget_exhaustedYour monthly budget is used up.Wait for the date in x-sc-budget-renews-at, or add budget.
402free_quota_exhaustedYour free trial credit is used up.Choose a plan.
402payment_requiredA payment failed and access is paused.Update your payment method in Billing.
403company_access_deniedThis company key has been disabled.Ask your company admin.
429rate_limit_exceededToo many requests.Wait for retry-after seconds, then retry.
503service_unavailableThe model is temporarily unavailable after retries.Retry after retry-after, or use smart routing.

Other 4xx errors from the model provider are passed through with provider details removed.

Retries​

Standard Compute already retries provider errors before responding. When you retry:

  • Retry 429 and 503 after the retry-after delay, with exponential backoff.
  • Don't retry 400, 401, 402 or 403 without changing the request or your account.

Response headers​

HeaderDescription
retry-afterSeconds to wait before retrying, on 429 and 503.
x-sc-budget-renews-atWhen your budget resets, on budget_exhausted.
x-sc-gatedWhy a request was blocked, for example budget_exhausted or rpm_limit.