Contents

Errors

Errors return a JSON body with a code and a message. The message says what happened and what to do.

Error body
{
  "error": {
    "message": "No node is serving deepseek/deepseek-v4.1-flash right now; retry shortly",
    "type": "rate_limit_error",
    "code": "model_not_available"
  }
}
HTTPCode and message
400invalid_request
"Invalid request: `messages` is required"
401invalid_api_key
"API key not recognised"
401sail_signature_invalid
"This Sail key works only from the machine that signed in with it; run sail login on this machine"
401sail_clock_skew
"The request's time is more than 5 minutes from the gateway's; check this machine's clock"
402insufficient_credits
"Workspace has $0.00 in credits; add credits on the billing page"
402key_limit_reached
"This key has reached its monthly limit of $5.00; raise the limit on the keys page"
403region_not_allowed
"This key is not allowed in region {region}; allowed: {regions}"
403workspace_suspended
"This workspace is suspended; contact hello@safeailabs.ai"
403sail_key_requires_sail
"This key works only from Sail; create an API key at https://safeailabs.ai/keys for other clients"
404model_not_found
"The model `deepseek-r2` does not exist or is not available"
404not_found
"No route for POST /v1/embeddings"
413context_length_exceeded
"This request needs about 40000 tokens of context, over the model's limit of 32768"
429rate_limited
"Rate limit of 5000 requests / min reached; retry after 12 s"
429rate_limited
"This workspace's API plan allows 8 requests at once; none finished within 60 s"
429too_many_attempts
"Too many wrong API keys from this address; retry in a minute"
429model_not_available
"No node is serving deepseek/deepseek-v4.1-flash right now; retry shortly"
503region_unavailable
"This region is not serving requests right now; retry later or use another region"
503service_unavailable
"Keys cannot be checked right now; retry shortly"

429 and 503 carry a Retry-After header in seconds. When every node serving the model is busy the answer is 429 with a Retry-After of 1 second and the number 429 as its code. A request is never retried in another region on your behalf. If you want a fallback region, call it yourself.

These docs as plain text for coding agents: llms.txt