Text to speech
Every native speech request uses client.audio.speech and the teen-v1 model.
speech = client.audio.speech.create(
model="teen-v1",
voice="default",
input="Generate speech with Teen V1.",
response_format="mp3",
)Build your speech flow
- Select
default, a public voice ID, or inline reference audio. - Send text with
audio.speech.create(). - Save the complete response or consume it while it is generated.
- Add generation controls only when the default output needs adjustment.
Continue with
| Task | Guide |
|---|---|
| Create a request | Create speech |
| Select a voice | Voices |
| Choose PCM, MP3, or WAV | Audio formats |
| Stream known text | HTTP and SSE streaming |
| Send text incrementally | WebSocket streaming |
| Keep an existing provider client | Provider patches |
