Skip to content

Errors

Rikaii returns standard HTTP status codes with a JSON body when something goes wrong. Always read the payload for the machine-readable error code and the message string.

Typical JSON body:

json
{
  "error": "rate_limit_exceeded",
  "message": "Rate limit exceeded. Please upgrade your plan or slow down.",
  "status": 429,
  "timestamp": "2026-05-07T12:00:00Z"
}

The error field is what clients should branch on; message is operator-safe (no stack traces).

HTTP status codes

StatusMeaning
401 UnauthorizedInvalid or missing API key, or malformed Authorization header (Bearer scheme required).
402 Payment RequiredPay-as-you-go monthly spend limit reached, no payment method on file when required, or another billing prerequisite failed.
403 ForbiddenAttempted to configure bring-your-own-key (BYOK) provider keys (add, update, or remove) without an active Pro subscription. Other authenticated Dashboard or account routes may return 403 when the signed-in user lacks permission.
429 Too Many RequestsRate limit exceeded for POST /v1/chat/completions. Retry with backoff; see Rate limits.

Other codes you may see:

StatusMeaning
400 Bad RequestMalformed JSON or invalid parameters.
503 Service UnavailableRate-limiting infrastructure temporarily unavailable; requests are fail-closed for protection.
500 Internal Server ErrorUnexpected failure—retry later; contact support if it persists.

Rikaii API documentation