CloseRouter

Errors

Errors always use one JSON shape.

Error JSON

JSON
{
  "error": {
    "code": "invalid_request",
    "message": "Request body must be a JSON object",
    "status": 400,
    "metadata": {
      "request_id": "..."
    }
  }
}

Code and cause

ErrorMeaning
400 invalid_requestinvalid JSON, missing model, unsupported parameter, or mixed free and paid fallback models.
401 invalid_api_keymissing or invalid key.
402 insufficient_balanceaccount balance is too low.
403 telegram_link_requiredlink Telegram on /settings before using a free model.
429 rate_limiteda request limit is exhausted; for the free-model daily limit metadata.limit_type is free_models_daily_requests and Retry-After is seconds until UTC midnight.
429 rate_limitedfor models sponsored by a Happy Hour promotion, metadata.limit_type is happy_hour_requests_per_minute and a separate per-user minute limit applies.
503 no_available_providerno route is currently available for the selected model and endpoint.
503 service_unavailablefree-model access checks are temporarily unavailable and the request is rejected before any provider call.
409 max_cost_exceededThe quote exceeds max_cost_usd. Obtain a new quote and review the amount before generating.
422 max_price_no_routeNo route matches the price limits. Check max_price and rates; no paid call was made.

Contact support

metadata.request_id is useful when contacting support.