Voice API
Your Own Speech Voice
Use your own Sarvam AI key and voice for everything TryVox speaks, instead of the platform voice.
By default, every Say in your VoxML is spoken by the platform voice. You can replace it with a voice from your own Sarvam AI account — your key, your model, your speaker, your quota.
This changes what callers hear. It does not change how you write VoxML: Say keeps working exactly as documented, and your voice is used automatically once it is active.
Scope: one voice per account
A voice is configured per account, and an account means whoever the credential belongs to:
| Who | Gets |
|---|---|
| Your account | Its own key and voice |
| Each of your sub-accounts | Its own key and voice, set independently |
There is no inheritance in either direction. A sub-account does not use its parent's voice, and configuring a voice on a sub-account never touches the parent's. A sub-account that has not configured one uses the platform voice.
This is deliberate for partners: your customers' calls spend their own Sarvam quota, not yours, and no customer can read or overwrite your key.
The endpoints below carry no account in the path — the account is whoever the credential identifies. A sub-account calling them with its own credentials configures its own voice, with nothing extra to pass.
Set a voice from the console
Voice → Settings → Speech, or go straight to /app/voice/speech.
- Paste your Sarvam API key.
- Choose a model and a speaker. The two are a pair — Sarvam speakers are model-specific, and a
bulbul:v3speaker sent againstbulbul:v4-flashis rejected by the provider. - Save. TryVox synthesizes a test phrase with your key immediately; the result is the status you see.
- Use Preview to hear the exact audio a caller would get.
Set a voice over the API
curl -X PUT https://api.tryvox.io/v1/tts/voice \
-u $TRYVOX_AUTH_ID:$TRYVOX_AUTH_TOKEN \
-H 'Content-Type: application/json' \
-d '{
"provider": "sarvam",
"name": "Sarvam Bulbul v4 Flash",
"api_key": "YOUR_SARVAM_KEY",
"model": "bulbul:v4-flash",
"speaker": "simran_en_customer",
"pace": 1.0
}'| Field | Type | Required | Description |
|---|---|---|---|
provider | string | yes | sarvam. The only provider today. |
api_key | string | yes | Your Sarvam key. Stored encrypted and never returned. |
model | string | yes | bulbul:v4-flash or bulbul:v3. |
speaker | string | no | A speaker valid for that model. Defaults to the model's default. |
name | string | no | Your own label for the integration. |
pace | number | no | Speaking rate. |
The response is the stored voice without the key, carrying the verification result:
{
"data": {
"provider": "sarvam",
"name": "Sarvam Bulbul v4 Flash",
"model": "bulbul:v4-flash",
"speaker": "simran_en_customer",
"status": "active",
"last_verified_at": "2026-11-19T09:14:22Z",
"pace": 1
}
}Status, and what it means for live calls
Saving does not take effect until the key has actually synthesized something. TryVox verifies on save and stores the outcome:
| Status | What your calls use |
|---|---|
active | Your voice. Verified working. |
pending | The platform voice. Saved but not yet proven. |
invalid_credentials | The platform voice. The key was rejected. |
disabled | The platform voice. |
Only active changes what callers hear. This is the point of the status: a wrong key degrades your settings page, never your live IVR. When something fails, last_error carries the provider's own message.
Speech also falls back to the platform voice if a synthesis attempt fails mid-call, so a provider outage makes your IVR sound different — not silent.
Other endpoints
| Method | Path | Purpose |
|---|---|---|
GET | /v1/tts/voice | The configured voice. Never returns the key. 404 means no voice is set. |
DELETE | /v1/tts/voice | Remove it and return to the platform voice. |
GET | /v1/tts/providers | Providers, models, their speaker shortlists and languages. |
GET | /v1/tts/speakers?model=bulbul:v4-flash | Speakers for a model, read live from Sarvam with your key where possible. |
POST | /v1/tts/voice/preview | Synthesize a phrase with your saved voice. Returns 8 kHz WAV — the same audio a call would hear. |
curl -X POST https://api.tryvox.io/v1/tts/voice/preview \
-u $TRYVOX_AUTH_ID:$TRYVOX_AUTH_TOKEN \
-H 'Content-Type: application/json' \
-d '{"text": "Your call is being connected.", "language": "en-IN"}' \
--output preview.wavWho may configure it
Speech settings hold a provider API key, so they are treated as credential management:
- An account owner or team admin may configure them.
- A sub-account may configure its own, by its login or by an API key issued to it.
- A team editor or viewer on someone else's account may not — including the preview, which renders with the stored key.
Notes
- The speaker list for a model is a shortlist, not the whole set —
bulbul:v4-flashalone has over 200. You may send any speaker id Sarvam accepts;GET /v1/tts/speakersreads the live set with your key. - Each model has a maximum text length per request.
GET /v1/tts/providersreports it. - Telephony audio is 8 kHz and TryVox selects that itself — format and sample rate are not yours to set.
Say'svoiceandengineparameters are unrelated to this. They do not select a provider; see Say.