/ttsSynthesize text to a WAV file, or stream raw PCM chunks with `streaming: true`.
Synthesize Speech
Converts text to audio in a single request.WAV mode. The default. The response body is a complete audio/wav file. The header carries X-Sample-Rate: 24000.Streaming mode. Set streaming: true for real-time audio, ready to play as the model speaks it. The response is audio/pcm with Transfer-Encoding: chunked and X-Encoding: pcm16. The body is contiguous little-endian signed 16-bit PCM at 24 kHz, mono, with no header or framing. Read the chunks in order and feed them straight into a 24 kHz mono playback buffer.Output format. Audio is 24 kHz, 16-bit, mono. WAV mode returns RIFF-headered audio/wav; streaming mode returns raw audio/pcm. Other codecs and sample rates are not currently exposed.
Request body
4textstringrequiredText to synthesize. 1–650 characters per request; every character counts toward billing. Use
POST /tts/batchfor longer scripts.languagestringoptionalenglish(default) orfrench.voice_idstringoptionalVoice identifier from
GET /voices. Omit this field to use the deployment default voice; legacy clients may passdefaultwith the same effect.streamingbooleanoptionalSet
truefor chunked PCM16 streaming instead of a complete WAV file. Defaultfalse.
Errors
6language (or an item's) is a local African language or Arabic: those are part of the Aethex enterprise platform. The body's language names it.
Use english or french in its standard form, or move the work to the Aethex enterprise platform.
The request names no voice, and no voice your account may use speaks its language: a local language's default voice is on a voice pool your account doesn't include. The body's kind and value name the pool.
Name a voice from GET /voices?language=…, which lists only the ones your account may use.
The voice_id resolves but has no active TTS model bound to it. The server returns the detail string "Voice not linked to an active TTS model" verbatim — match on that string.
Check the ID with GET /voices, or omit voice_id to use the default.
The text is over the 650-character synchronous TTS safety cap. The request returns 413 before synthesis starts.
Use POST /tts/batch for long-form text, or split the text at sentence boundaries and synthesize shorter realtime chunks.
text is empty or longer than the schema ceiling, language is not english or french, or one word in text is too long to speak (a long code, token or URL with no spaces). The error field gives the reason.
Send 1–650 characters of text and a supported language code, and write long codes with spaces between groups. For longer copy, use POST /tts/batch.
The synthesis service is starting up or scaling.
Retry after a short delay. A freshly-deployed voice may take a minute or two to warm up.
