Text-to-Speech
Text to Speech
Convert text to natural-sounding speech
POST
Request
Headers
string
required
Bearer token with your API key
string
required
application/json
Body
string
required
The text to convert to speech (max 5000 characters)
string
required
ID of the voice to use. Fetch available voices from
GET /voices.object
Nested audio configuration block (matches the upstream Inworld schema).
string
default:"LINEAR16"
Audio encoding for the streamed response. Options:
LINEAR16, OGG_OPUS.integer
default:"24000"
Output sample rate. Options:
16000, 24000, 48000.number
default:"1"
Speaking rate. Range
0.5 (slow) – 2.0 (fast). 1.0 = normal.integer
default:"50"
Voice consistency
0–100. 0 = expressive, 50 = balanced, 100 = consistent.integer
default:"75"
Voice match fidelity
0–100. 0 = loose, 75 = strong, 100 = exact clone.string
default:"WORD"
Set to
"WORD" to receive per-word timestamps in the final NDJSON chunk (timestampInfo). Omit or set to "NONE" to skip.string
Optional cross-lingual synthesis hint (e.g.
"en", "hi", "ar"). Required when the voice’s reference audio is in a different language than the input text. Auto-detected from voice metadata when omitted.Legacy flat keys (
sample_rate, audio_encoding) are still accepted for backwards-compatibility, but new integrations should send the nested audio_config object.Response
boolean
Indicates if the request was successful
string
Status message
string
Base64-encoded audio data
number
Audio sample rate in Hz
number
Duration of the audio in seconds
string
Audio encoding format
string
Audio output format