Using the API
Errors
Every error code, what it means and what to do about it.
Errors use the format of the endpoint you called (OpenAI or Anthropic), with a stable code.
Error codes
| Status | Code | Meaning |
|---|---|---|
| 400 | invalid_request_error | The body is not valid JSON or is missing model / messages (or input for embeddings). |
| 401 | authentication_error | Missing, malformed, unknown or revoked API key. |
| 402 | insufficient_balance | Your balance cannot cover the cheapest eligible offer. Deposit USDC. |
| 402 | key_budget_exceeded | This key would go over its spending budget. Raise or reset it in the dashboard. |
| 403 | permission_error | The account is suspended, or the key may not use this endpoint. |
| 404 | model_not_found | Unknown model id. List ids with GET /v1/models. |
| 404 | no_sellers_for_model | No healthy offer for this model right now under your trust settings. |
| 404 | minimum_discount_not_met | No offer meets your minimum discount. The message names the best one available. |
| 429 | rate_limited | Too many requests. Wait for the time in Retry-After. |
| 4xx/5xx | upstream_error | The seller rejected the request, for example a parameter the model does not support. The message gives the status and a standard code. |
| 503 | upstream_unavailable | Every attempted offer failed. Retry, or loosen your filters. |