spiderai
Log inGet an API key

Troubleshooting

When the API returns an error, the HTTP status narrows down the kind of problem, and code or error.type in the body names the cause. Rather than reading the whole list, paste the full error into the search box below and the matching entry is picked out for you.

Entries come from what the spiderai gateway really returns · last checked 2026-11-29

  • 4xxSomething in the request or accountCorrect the key, balance or parameters first; resending unchanged fails again
  • 429Sending too fast or too muchPause before resending; after repeated failures, double the pause each time
  • 5xxSomething at the model serviceRetry after a while; if it doesn’t clear, move to another group from the same provider

What an error looks like

Requests stopped at our end (a wrong key, too little balance) get the left-hand shape. Errors after the request has gone on to the model service come back in the format of the API you called, so clients and SDKs parse them as usual.

Stopped by us
{
  "code": "INVALID_API_KEY",
  "message": "Invalid API key"
}
Anthropic format
{
  "type": "error",
  "error": {
    "type": "rate_limit_error",
    "message": "Concurrency limit exceeded for user, please retry later"
  }
}
OpenAI format
{
  "error": {
    "type": "insufficient_quota",
    "message": "api key 额度已用完"
  }
}

A request that fails without using anything costs nothing. If a streamed reply breaks off, what was already output is billed at actual usage, and every charge can be matched in Usage.

1Keys and account status

The key is mistyped, turned off or past its expiry, or the account itself is unavailable.

401
API_KEY_REQUIREDFix, then resendNot charged

No API key in the request

API key is required in Authorization header (Bearer scheme), x-api-key header, or x-goog-api-key header

What to doSend Authorization: Bearer sk-… in a header; Anthropic-style clients can use x-api-key.

401
INVALID_API_KEYFix, then resendNot charged

The key does not exist, or was copied with characters missing or added

Invalid API key

What to doCopy the full key again from API keys and check there are no spaces or line breaks around it.

401
API_KEY_DISABLEDFix, then resendNot charged

The key is turned off

API key is disabled

What to doTurn it back on in API keys, or create a new one.

403
API_KEY_EXPIREDFix, then resendNot charged

The key has expired

API key 已过期

What to doExtend it in API keys, or create a key that does not expire.

403
ACCESS_DENIEDFix, then resendNot charged

The request came from an IP that is not on this key’s allowlist, or is on its blocklist

Access denied. Your IP is …

What to doChange the key’s IP limits in API keys. The IP in the message is the address we saw.

401
USER_INACTIVEContact usNot charged

The account is suspended

User account is not active

What to doAsk us about the account through Contact.

403
permission_errorFix, then resendNot charged

The key has no group

API key is not assigned to a group

What to doCreate a new key in API keys and pick a group when you create it.

400
api_key_in_query_deprecatedFix, then resendNot charged

The key was sent in the URL

API key in query parameter is deprecated. Please use Authorization header instead.

What to doSend it in a header instead, as in the first entry of this section.

429
INVALID_AUTH_RATE_LIMITEDWait, then retryNot charged

Too many wrong keys from the same network in a short time

Too many invalid authentication attempts; retry later

What to doCheck the key, then wait about a minute.

2Balance and spending caps

The money in your account, and the caps and period limits you set on a single key.

403
INSUFFICIENT_BALANCEFix, then resendNot charged

Not enough balance

Insufficient account balance

What to doTop up; it works as soon as the payment arrives.

429
API_KEY_QUOTA_EXHAUSTED · insufficient_quotaFix, then resendNot charged

This key’s own cap is used up; your balance may still be fine

api key 额度已用完

What to doRaise or remove the key’s cap in API keys.

429
rate_limit_exceededWait, then retryNot charged

The key’s 5-hour, daily or 7-day spending limit is reached

api key 5小时限额已用完api key 日限额已用完api key 7天限额已用完

What to doWait for the period to reset, or change the limits in API keys.

3Concurrency and rate limits

More requests at once than allowed, or the model service is throttling.

429
gateway_concurrency_limitCan retryNot charged

Too many of your requests are running at the same time

Concurrency limit exceeded for user, please retry later

What to doWait for earlier requests to finish, or lower the concurrency in your client. For higher concurrency, contact us.

429
gateway_queue_fullCan retryNot charged

Too many requests are waiting in line

Too many pending requests, please retry later

What to doTry again shortly; if the response has a Retry-After header, wait that many seconds.

429
rate_limit_errorCan retryNot charged

The model service is rate limiting

Upstream rate limit exceeded, please retry laterAll available accounts are currently rate-limited. Please retry later.

What to doRetry later and double the wait after each failure. Retrying straight away gets a 503 next (see Model service and connection). If it keeps happening, switch to another group from the same provider.

4Request, model and address

Something in the request itself: parameters, model name, API address or size.

400
invalid_request_errorFix, then resendNot charged

The request or a parameter is wrong, for example no model, an empty body or invalid JSON

model is requiredFailed to parse request bodyRequest body is emptyInvalid request body

What to doFix what the message says and send again.

400
invalid_request_errorFix, then resendNot charged

The conversation is longer than this model’s context limit

prompt is too long: … tokens > … maximum

What to doCompact the conversation or start a new one; for longer contexts, use a model with a higher limit.

404
not_found_errorCan retryNot charged

The model service does not have this model in this group right now

Resource not foundModel "…" is not available for this group

What to doCheck Status first; use another model in the group, or try again later.

404
404Fix, then resendNot charged

The API address is wrong

404 page not found

What to doUse https://api.spiderai.fun/v1 for OpenAI formats and https://api.spiderai.fun for Anthropic; avoid …/v1/v1.

405
405Fix, then resendNot charged

The website address was used as the API address, so a web page came back

Returns a web page, not JSON

What to doThe API lives at https://api.spiderai.fun, not https://spiderai.fun.

413
413Fix, then resendNot charged

The request is too large

Request body too large, limit is 256MB

What to doUse smaller images, fewer attachments, or split it into several requests.

5Not supported by this group

This group does not accept this kind of call: switch groups, or use a client and API format it supports.

403
permission_errorFix, then resendNot charged

The Claude for Claude Code group only works in Claude Code

This group is restricted to Claude Code clients (/v1/messages only)this group only allows Claude Code clients

What to doFor other clients, use a key from Claude Economy, Claude General or Claude Official API.

403
permission_errorFix, then resendNot charged

A GPT group was called in the Anthropic format (/v1/messages)

This group does not allow /v1/messages dispatch

What to doCall GPT groups in the OpenAI format (/v1/chat/completions or /v1/responses); for Claude Code, use a key from a Claude group.

400
INVALID_ARGUMENTFix, then resendNot charged

The Gemini native API (/v1beta/…) was called with a key that is not in a Gemini group

API key group platform is not gemini

What to doUse a key from a Gemini group, or switch to the OpenAI format /v1/chat/completions.

403400
permission_error · invalid_request_errorFix, then resendNot charged

This group cannot generate images (the Anthropic, Chat Completions and Gemini APIs return 400)

Image generation is not enabled for this group

What to doUse a group that can generate images; see the group notes on Pricing.

404
not_found_errorFix, then resendNot charged

The images API (/v1/images/…) was called with a key from a group that cannot generate images

Images API is not supported for this platform

What to doUse a key from a group that can generate images.

6Content refused

The content did not pass the model service’s review. It has nothing to do with your key or balance.

400502
invalid_request_error · upstream_errorFix, then resendNot charged

The content did not pass the model service’s safety review. The message comes from the model service and usually mentions safety, policy or moderation; sometimes it shows up as Upstream access forbidden (see Model service and connection)

Returns a web page, not JSON

What to doChange or remove what triggered it and retry. If every request is refused, check your client’s plugins, system prompt or persona, turn them off and start a new conversation. Other groups usually refuse it too.

7Model service and connection

Trouble at the model service or on our connection to it; nothing to do with your key or account.

502
upstream_errorCan retryNot charged

The model service returned an error, or the connection dropped midway

Upstream service temporarily unavailable

What to doRetry later; if it persists, check Status or switch to another group from the same provider.

502
upstream_errorCan retryNot charged

The model service refused this request. Usually it is busy; sometimes the content was refused. It has nothing to do with your key or balance, and “contact administrator” does not mean your account has a problem

Upstream access forbidden, please contact administrator

What to doRetry later; if it keeps happening, start a new conversation or switch to another group from the same provider.

503
overloaded_errorCan retryNot charged

The model service is overloaded

Upstream service overloaded, please retry later

What to doWait a few seconds to a few minutes and retry.

502503
server_error · api_errorCan retryNot charged

This group has no line available right now. Retrying straight after a rate limit also shows this; if it happens every time, the group most likely does not have this model

All available accounts exhaustedNo available accounts…Service temporarily unavailable

What to doCheck on Pricing that the group has the model and that the model ID is right; if it is, wait a little or switch to another group from the same provider.

502
upstream_errorContact usNot charged

The line from us to the model service has a problem; it is not your key

Upstream authentication failed, please contact administrator

What to doPlease contact us with the time of the request and the model.

503
billing_service_errorCan retryNot charged

Our billing service is temporarily unavailable

Billing service temporarily unavailable. Please retry later.

What to doRetry later; if it persists, contact us.

A streamed reply stops midway

Whatever was output before the break is billed at actual usage; simply send again. For long-running work such as Claude Code or Codex, leave streaming on (stream: true): an idle connection is not dropped, and errors show up right away.

Ask us to look into it

Send us the error code and full message, the X-Request-Id response header, and the time and model. Once signed in, you can see each failure under Failed requests in Usage. Don’t send the whole API key; its name or first few characters are enough.

Contact us