Prerequisites: API key
Available TTS models
Pass the hosted model ID in themodel field of any TTS request. If you omit
model, English defaults to the standard hosted model.
Use the
latest IDs for most applications. Use a pinned dated ID when you need
the same model snapshot across deploys. You can also fetch current public IDs
from List Supported Models.
1
Get a Voice ID (Optional)
Optionally get a
voice_id from your dashboard or clone a voice. Skip this to use the default voice.2
Generate Speech
Generate speech from text. Include
voice_id if you have one, or omit it to use the default voice. See the Generate Speech endpoint for details.Streaming
HTTP Streaming (Simple)
For simple request/response streaming, use the HTTP streaming endpoint:WebSocket Streaming (Optimal for Conversational AI)
For lowest latency in multi-turn conversations, use the Multi-Context WebSocket (/multi-stream):
Supported Languages
The TTS API supports multiple languages. Specify thelanguage parameter using ISO 639-1 language codes. If not provided, the API defaults to English (en).
Model Selection: The API automatically selects the appropriate model based on the language. English uses
voiceai-tts-v1-latest, while all other languages use voiceai-tts-multilingual-v1-latest. For Lite, explicitly set voiceai-tts-lite-v1-latest and language: "en". See the Model ID list for all supported model IDs.Audio Output
The TTS API supports multiple audio formats with various sample rates and bitrates. Basic formats (mp3, wav, pcm) output at 32kHz sample rate. Format-specific options allow you to control sample rate and bitrate.
32kHz Formats
MP3 Formats (with sample rate and bitrate)
Opus Formats (with sample rate and bitrate)
PCM Formats (with sample rate)
Allpcm_* formats use 16-bit signed little-endian mono at the specified sample rate.
WAV Formats (with sample rate)
Telephony Formats
Voice Cloning
Create custom voices from audio samples
Streaming
HTTP & WebSocket streaming (WebSocket for lowest latency)
API Reference
Complete endpoint documentation