Prerequisites
1
Create an API key
Sign in to the Chariot dashboard and generate an API key. Copy it somewhere safe, you send it on every request.
2
Pick a voice
List the available voices and copy a
voice_id whose models array includes chariot-multilingual-v1:Synthesize speech
Send text toPOST /v1/tts and save the returned WAV:
Credit-Utilized header reports the cost (1 credit per character).
These examples explicitly select Chariot Multilingual v1 with "model_type": "chariot-multilingual-v1". Choose a voice that supports this model. Omitting the field uses chariot-v0. See Models for limits and speaking rates.
Stream for low latency
For real-time playback, usePOST /v1/tts/stream. It returns raw 16-bit PCM at 44.1 kHz as it is generated, so you can start playing before synthesis finishes:
Python
The stream is headerless PCM (
audio/L16, 44100 Hz, mono, signed 16-bit little-endian), not a WAV file. Your player must be configured for that format, or you must prepend a WAV header yourself. The X-audio-url header points to a WAV archive uploaded after generation. Archiving is best effort, so retain the stream if you need a guaranteed local copy.Next steps
Choose your API
When to use REST, HTTP streaming, or WebSocket.
WebSocket streaming
Send text incrementally over a persistent connection.
Errors & status codes
Handle failures gracefully.
Credits & pricing
Understand what each request costs.