OpenAI-compatible text to speech. The response body is the raw audio.
voice takes the provider’s own voice ids, never OpenAI aliases; GET
/v1/models lists the voices and endpoint for each speech model.
Formats differ by model because the providers do. xai/grok-voice-tts-1.0
encodes natively (mp3, wav, pcm) and bills 1.00/1M in and $20.00/1M out.
Gateway API key (imp-rt-...) from POST /v1/accounts or /v1/keys.
xai/grok-voice-tts-1.0, google/gemini-3.1-flash-tts-preview Text to speak. Both models accept inline expressive tags.
A voice id the chosen model supports (see GET /v1/models).
"eve"
Defaults to the model's native format: mp3 for xai, wav for google. A format the model cannot produce is a 400, never a substitution.
mp3, wav, pcm Playback rate, xai/grok-voice-tts-1.0 only. Gemini has no rate control, so any value other than 1 is a 400 there rather than a silently ignored parameter.
0.7 <= x <= 1.5The synthesized audio.
The response is of type file.