runanything.ai

Errors & limits

Errors use OpenAI's wire format, so SDKs raise their native error classes (AuthenticationError, RateLimitError, BadRequestError, …) exactly as they do against OpenAI:

{
  "error": {
    "message": "'input' is too long: 5000 characters (maximum 4096).",
    "type": "invalid_request_error",
    "param": "input",
    "code": null
  }
}

Status codes

StatustypeWhen
400invalid_request_errorMalformed body, unknown voice/model, unsupported format, out-of-range values. param names the offending field.
401invalid_request_errorMissing or unknown API key (code: invalid_api_key).
413invalid_request_errorUploaded file over the 4 MB limit (code: file_too_large).
429rate_limit_errorToo many requests (code: rate_limit_exceeded). Honor the Retry-After header.
502api_errorSpeech synthesis or transcription failed upstream. Safe to retry.
504api_errorThe request timed out (code: timeout). Retry, or shorten the input.

Limits

TTS input4,096 characters per request
TTS speed0.25 – 4.0
STT file size4 MB per file
STT containerswebm, mp4, ogg, wav, mp3
Playground demo300 characters, rate-limited per IP

Not supported yet

  • TTS response_format: opus, flac (use mp3/wav/aac/pcm).
  • STT response_format: srt, vtt, and segment-level timestamps.
  • Server-sent-events streaming (stream_format: sse) — use response_format: pcm for streaming audio.
Per-key rate limits are generous and set per project during the beta — if you're hitting 429s or need any of the unsupported features, email help@runanything.ai and we'll sort it out.