Turn any text into natural-sounding audio with a single API call. Powered by neural TTS, the TTS API returns a hosted MP3/PCM audio URL — ideal for IVR prompts, voice flows, accessibility, e-learning, and dynamic content. Billed per character from your prepaid wallet.
The TTS API lets you synthesize lifelike speech from plain text. Send your text, choose a voice preset and output format, and receive a hosted audio URL you can play, embed, or stream anywhere.
Unlike clip-based TTS, there is nothing to pre-record — the neural engine generates natural speech on demand, so every response is unique.
Our neural TTS engine generates lifelike speech from any text.
Every synthesis returns a public MP3/PCM URL served by the platform.
Pay ₹0.001 per character (₹0.01 minimum) from your prepaid wallet.
https://APIURL.tetrax.in/v1.The TTS API uses API key authentication. You must include your trx_tts_* API key in the x-api-key header of every request.
trx_tts_* key.x-api-key header.Authorization: Bearer <token>.Synthesize your first clip in under a minute. Replace the API key and text with your own values.
audio_url. Your wallet is charged only after a successful synthesis — a provider failure never bills you.Six natural voice presets are available out of the box. Use the GET /v1/tts/voices endpoint to fetch the live list.
| Voice ID | Style | Description |
|---|---|---|
| default | Natural | Balanced, natural-sounding default voice |
| alloy | Bright | Bright and energetic female voice |
| echo | Warm | Warm and confident male voice |
| fable | Expressive | Expressive, storybook female voice |
| onyx | Deep | Deep and authoritative male voice |
| nova | Soft | Soft and clear female voice |
| shimmer | Articulate | Neutral and articulate female voice |
/v1/tts/synthesizeConvert text to speech and receive a hosted audio URL. Billed per character after successful synthesis.
Response
{
"success": true,
"generation_id": "gen_xxx",
"job": {
"id": 1,
"characters": 26,
"voice": "alloy",
"format": "mp3",
"audio_url": "https://APIURL.tetrax.in/v1/tts/audio/s2_1_xxx.mp3",
"charge": 0.03
},
"model": "tetrax-neural-tts",
"pricing": { "per_char": 0.001, "minimum_bill": 0.01 }
}| Parameter | Type | Required | Description |
|---|---|---|---|
| text | string | Yes | The text to synthesize. Max 5,000 characters. |
| voice | string | No | Voice preset. Defaults to "default". See voice presets above. |
| format | string | No | Output format: mp3 or pcm. Defaults to mp3. |
/v1/tts/jobsRetrieve synthesis history for your account. Requires dashboard JWT auth.
Response
{
"jobs": [
{
"id": 1,
"text": "Hello! Welcome to TetraX.",
"characters": 26,
"voice": "alloy",
"format": "mp3",
"audio_url": "https://APIURL.tetrax.in/v1/tts/audio/s2_1_xxx.mp3",
"status": "completed",
"charge": 0.03,
"created_at": "2026-07-23T12:00:00.000Z"
}
],
"total": 12
}/v1/tts/analyticsGet month-to-date synthesis analytics including character and spend totals.
Response
{
"summary": {
"total_syntheses": 12,
"total_characters": 1240,
"total_charge": 1.24,
"avg_chars_per_job": 103
}
}/v1/tts/voicesList the available voice presets for the S2.1 Pro model.
Response
{
"voices": [
{ "id": "default", "name": "Default (Natural)", "description": "Balanced, natural-sounding default voice" },
{ "id": "alloy", "name": "Alloy", "description": "Bright and energetic female voice" }
]
}The TTS API uses standard HTTP status codes to indicate success or failure. Error responses include a descriptive message in the response body.
| Code | Description |
|---|---|
| 200 | OK — Speech synthesized and audio URL returned. |
| 400 | Bad Request — Missing text, invalid voice, or unsupported format (only mp3/pcm). |
| 401 | Unauthorized — Missing or invalid API key. Include the x-api-key header with a valid trx_tts_ key. |
| 403 | Forbidden — Invalid API key type. A Tetrax TTS API Key (trx_tts_...) is required. |
| 402 | Payment Required — Insufficient wallet balance. Top up from the Billing page. |
| 429 | Too Many Requests — Rate limit exceeded for your account. |
| 502 | Bad Gateway — The TTS provider failed to synthesize audio. Retry the request (you were not charged). |
| 503 | Service Unavailable — TTS provider is not configured on the platform yet. |
Rate limits protect the API from abuse and ensure fair usage across all customers. Limits are enforced per API key and configured per account (set per account — no monthly fee).
| Account | Max Syntheses Per Minute | Price Per Character |
|---|---|---|
| Standard | Up to 240/min | ₹0.001/char |
| Enterprise | 600/min | Custom |
The TTS API uses prepaid wallet billing at ₹0.001/char per character with a ₹0.01 minimum bill per synthesis — no subscriptions, no monthly fees. The charge is deducted from your wallet only after a successful synthesis, and the exact amount is recorded in your wallet transaction history under tts_usage.
Same rate for every account — no subscriptions, no monthly fees. ₹0.01 minimum bill per synthesis.
Test the TTS API interactively from the TTS Playground in your dashboard.
Was this page helpful?
Help us improve our documentation.