Regenerate a recording from text

Generates new speech for an existing recording and replaces its audio; each call is billable. The audio is replaced in place even while the recording is in use, so anything that plays it hears the new audio. Sending a different name gives the recording a new filename and deletes the old audio file, which is refused while anything uses the recording. The recording's text and voice are replaced by this request's; a tts.voice you omit takes the default.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required

Identifier of the recording to re-synthesize in place.

Body Params
tts
object
required

What to speak and how. tts.input is required.

string
required

The text to speak. Required; a missing tts.input is a 400.

string

Speech model: gemini-3.8-flash-tts (default) or gemini-3.8-flash-lite-tts. Any other value is a 400 with code tts_model_invalid, and the response's valid_models lists the accepted values.

string

Voice ID to speak in. Defaults to fr-ca-csagent-5. An unknown ID is a 400 with code tts_voice_invalid, and the response's valid_voices lists every voice you can use.

string

Plain-language direction for how the text is spoken (tone, pace, clarity, how to pronounce particular names), up to 500 characters. Defaults to Professional, slow, and enunciate clearly. Longer text is a 400 with code tts_style_invalid.

string

New name for the recording. A different name gives it a new filename and deletes the old audio file; the same name, or none, keeps the existing file.

string

Description of the recording. Defaults to TTS: followed by the first 100 characters of tts.input.

Responses
200

The recording's audio was regenerated and its details updated.

401

Missing or invalid API key.

409

The recording can't be regenerated here: a call flow created it (managed_by_call_flow; edit it in that call flow), you sent a new name while something uses it (sound_in_use, with uses listing where), or its audio file isn't a WAV file (send a new name to regenerate it under one).

502

Speech generation failed (TTS Generation Failed), or the updated recording could not be saved. Retry the request.

Language
Credentials
Bearer
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json