Integrate Sarvam AI into the workflow. Generate natural Indian-language and Hinglish speech with Bulbul voices, transcribe or translate voice notes and call recordings of up to 2 hours with Saaras, with speaker labels, translate and transliterate short text, and detect the language and script of a message.
Generate natural Indian-language or Hinglish speech with Sarvam Bulbul voices and save it as an audio file
| Parameter | Type | Required | Description |
|---|
text | string | Yes | The text to speak, up to 3500 characters (text over 2500 characters uses the streaming endpoint; 1500 on bulbul:v2). Supports Hinglish and other code-mixed text (e.g., "Namaste! Aapka order kal deliver hoga.") |
apiKey | string | Yes | Sarvam API subscription key |
languageCode | string | Yes | BCP-47 language of the text: bn-IN, en-IN, gu-IN, hi-IN, kn-IN, ml-IN, mr-IN, od-IN, pa-IN, ta-IN, or te-IN |
model | string | No | Bulbul model: bulbul:v4-flash (default), bulbul:v3, or bulbul:v2 |
speaker | string | No | Speaker voice for the chosen model (e.g., "shubh_enhi_ads" on bulbul:v4-flash, "priya" on bulbul:v3, "anushka" on bulbul:v2) |
pace | number | No | Speech speed: 0.5 to 2.0 on v3/v4, 0.3 to 3.0 on v2 (default 1.0) |
temperature | number | No | Expressiveness from 0.01 to 1.0 (default 0.6); bulbul:v3 and bulbul:v4-flash only |
pitch | number | No | Voice pitch from -0.75 to 0.75 (default 0); bulbul:v2 only |
loudness | number | No | Loudness from 0.3 to 3.0 (default 1.0); bulbul:v2 only |
sampleRate | number | No | Output sample rate in Hz: 8000, 16000, 22050 (default), 24000, 32000, 44100, 48000 |
outputCodec | string | No | Output audio codec: wav (default), mp3, aac, flac, linear16, mulaw, or alaw |
stream | boolean | No | Use the REST streaming endpoint, which returns raw audio and accepts up to 3500 characters |
bitrate | string | No | Streaming endpoint only: 32k, 64k, 96k, 128k (default), or 192k |
| Parameter | Type | Description |
|---|
audioUrl | string | URL to the generated audio file |
audioFile | file | Generated audio file (UserFile) |
characterCount | number | Number of characters spoken |
format | string | Audio format |
transcript | string | Transcribed text (English text for Speech to English Text) |
segments | json | Segments (text, start, end in seconds, speaker) when timestamps or speaker labels are on |
jobId | string | Sarvam batch job ID (long audio, or audio over 30 seconds) |
jobState | string | Job state: Accepted, Pending, Running, Completed, or Failed |
failureReason | string | Why the batch job failed, when it failed |
language | string | BCP-47 code of the predominant spoken language |
languageProbability | number | Confidence (0 to 1) in the detected spoken language |
translatedText | string | Translated text |
transliteratedText | string | Text written in the target script |
sourceLanguageCode | string | Detected or provided source language code |
languageCode | string | Detected language code (e.g. hi-IN) |
scriptCode | string | Detected script code (e.g. Latn, Deva) |
requestId | string | Sarvam request ID |
Transcribe Indian-language, English, or Hinglish speech with Sarvam Saaras; audio over 30 seconds runs as a batch job automatically
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
model | string | No | Saaras model: saaras:v4 (default) or saaras:v3 |
audioFile | file | No | Audio or video file (e.g., WAV, MP3, AAC, OGG, OPUS, FLAC, M4A, WEBM). Audio over 30 seconds uses the Sarvam Batch API automatically (up to 2 hours) |
audioFileReference | file | No | Reference to audio/video file from previous blocks |
language | string | No | BCP-47 language of the audio (e.g., "hi-IN", "ta-IN") or "unknown" to auto-detect |
timestamps | string | No | none, or sentence/word for chunk-level (sentence or phrase) timestamps |
keyterms | array | No | Up to 50 names, places, or brand terms (64 characters each) to bias recognition toward; saaras:v4 only |
mode | string | No | Output mode: transcribe (default), verbatim (no normalization), translit (Roman script), or codemix (English words in English, Indic words in native script) |
| Parameter | Type | Description |
|---|
audioUrl | string | URL to the generated audio file |
audioFile | file | Generated audio file (UserFile) |
characterCount | number | Number of characters spoken |
format | string | Audio format |
transcript | string | Transcribed text (English text for Speech to English Text) |
segments | json | Segments (text, start, end in seconds, speaker) when timestamps or speaker labels are on |
jobId | string | Sarvam batch job ID (long audio, or audio over 30 seconds) |
jobState | string | Job state: Accepted, Pending, Running, Completed, or Failed |
failureReason | string | Why the batch job failed, when it failed |
language | string | BCP-47 code of the predominant spoken language |
languageProbability | number | Confidence (0 to 1) in the detected spoken language |
translatedText | string | Translated text |
transliteratedText | string | Text written in the target script |
sourceLanguageCode | string | Detected or provided source language code |
languageCode | string | Detected language code (e.g. hi-IN) |
scriptCode | string | Detected script code (e.g. Latn, Deva) |
requestId | string | Sarvam request ID |
Translate speech in any supported Indian language directly into English text with Sarvam Saaras; audio over 30 seconds runs as a batch job automatically
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
model | string | No | Saaras model: saaras:v4 (default) or saaras:v3 |
audioFile | file | No | Audio or video file (e.g., WAV, MP3, AAC, OGG, OPUS, FLAC, M4A, WEBM). Audio over 30 seconds uses the Sarvam Batch API automatically (up to 2 hours) |
audioFileReference | file | No | Reference to audio/video file from previous blocks |
language | string | No | BCP-47 language of the audio (e.g., "hi-IN", "ta-IN") or "unknown" to auto-detect |
timestamps | string | No | none, or sentence/word for chunk-level (sentence or phrase) timestamps |
keyterms | array | No | Up to 50 names, places, or brand terms (64 characters each) to bias recognition toward; saaras:v4 only |
| Parameter | Type | Description |
|---|
audioUrl | string | URL to the generated audio file |
audioFile | file | Generated audio file (UserFile) |
characterCount | number | Number of characters spoken |
format | string | Audio format |
transcript | string | Transcribed text (English text for Speech to English Text) |
segments | json | Segments (text, start, end in seconds, speaker) when timestamps or speaker labels are on |
jobId | string | Sarvam batch job ID (long audio, or audio over 30 seconds) |
jobState | string | Job state: Accepted, Pending, Running, Completed, or Failed |
failureReason | string | Why the batch job failed, when it failed |
language | string | BCP-47 code of the predominant spoken language |
languageProbability | number | Confidence (0 to 1) in the detected spoken language |
translatedText | string | Translated text |
transliteratedText | string | Text written in the target script |
sourceLanguageCode | string | Detected or provided source language code |
languageCode | string | Detected language code (e.g. hi-IN) |
scriptCode | string | Detected script code (e.g. Latn, Deva) |
requestId | string | Sarvam request ID |
Translate short text between English and Indian languages with Sarvam, in a formal, colloquial, or code-mixed (Hinglish) tone
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
input | string | Yes | Text to translate: up to 1000 characters on mayura:v1, 2000 on sarvam-translate:v1 |
sourceLanguageCode | string | Yes | BCP-47 source language (e.g., "en-IN", "hi-IN") or "auto" to detect it (mayura:v1 only) |
targetLanguageCode | string | Yes | BCP-47 target language (e.g., "hi-IN", "ta-IN", "en-IN") |
model | string | No | mayura:v1 (11 languages, all tones, auto-detect) or sarvam-translate:v1 (all 22 scheduled Indian languages, formal only) |
mode | string | No | Tone: formal (default), modern-colloquial, classic-colloquial, or code-mixed (mayura:v1 only for non-formal tones) |
speakerGender | string | No | Speaker gender for better translations: Male or Female |
outputScript | string | No | Output transliteration style (mayura:v1 only): roman, fully-native, or spoken-form-in-native |
numeralsFormat | string | No | international (0-9, default) or native numerals |
| Parameter | Type | Description |
|---|
translatedText | string | Translated text in the target language |
sourceLanguageCode | string | Detected or provided source language code |
requestId | string | Sarvam request ID |
Convert text between Roman and Indian scripts while keeping its pronunciation, e.g. "namaste" to "नमस्ते"
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
input | string | Yes | Text to transliterate |
sourceLanguageCode | string | Yes | BCP-47 language of the input (e.g., "en-IN" for Romanized text, "hi-IN") or "auto" |
targetLanguageCode | string | Yes | BCP-47 language whose script to write in (e.g., "hi-IN" for Devanagari, "en-IN" for Roman) |
numeralsFormat | string | No | international (0-9, default) or native numerals |
spokenForm | boolean | No | Rewrite the text in natural spoken form, e.g. "9:30am" as words (no effect when the target is en-IN) |
spokenFormNumeralsLanguage | string | No | With spoken form, speak numbers in native (default) or english |
| Parameter | Type | Description |
|---|
transliteratedText | string | Text written in the target script |
sourceLanguageCode | string | Detected or provided source language code |
requestId | string | Sarvam request ID |
Detect the language and script of a short text, e.g. Hindi written in Roman script (Hinglish) or Devanagari
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
input | string | Yes | Text to identify, up to 1000 characters |
| Parameter | Type | Description |
|---|
languageCode | string | Detected BCP-47 language code (e.g., hi-IN), or null when undetected |
scriptCode | string | Detected script (e.g., Latn for Roman, Deva for Devanagari), or null |
requestId | string | Sarvam request ID |
Transcribe a call or meeting recording of up to 2 hours with the Sarvam Batch API, with optional speaker labels and sentence timestamps
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
model | string | No | Saaras model: saaras:v4 (default) or saaras:v3 |
audioFile | file | No | Audio or video file (e.g., WAV, MP3, AAC, OGG, OPUS, FLAC, M4A, WEBM). Audio over 30 seconds uses the Sarvam Batch API automatically (up to 2 hours) |
audioFileReference | file | No | Reference to audio/video file from previous blocks |
language | string | No | BCP-47 language of the audio (e.g., "hi-IN", "ta-IN") or "unknown" to auto-detect |
timestamps | string | No | none, or sentence/word for chunk-level (sentence or phrase) timestamps |
keyterms | array | No | Up to 50 names, places, or brand terms (64 characters each) to bias recognition toward; saaras:v4 only |
mode | string | No | Output mode: transcribe (default), translate (to English), verbatim, translit (Roman script), or codemix |
withTimestamps | boolean | No | Return sentence-level timestamps |
withDiarization | boolean | No | Label each speaker turn (e.g., agent and customer on a call) |
numSpeakers | number | No | Expected number of speakers when speaker labels are on (e.g., 2 for a call) |
maxWaitSeconds | number | No | How long to wait for the job, 30 to 7200 seconds (default 600, capped by the run time limit). If it is not done, the error includes the job ID for Get Transcription Job |
| Parameter | Type | Description |
|---|
jobId | string | Sarvam batch job ID |
Check a Sarvam batch transcription job and return its transcript once it has completed
| Parameter | Type | Required | Description |
|---|
apiKey | string | Yes | Sarvam API subscription key |
jobId | string | Yes | Batch job ID returned by Transcribe Long Audio |
| Parameter | Type | Description |
|---|
jobId | string | Sarvam batch job ID |
jobState | string | Job state: Accepted, Pending, Running, Completed, or Failed |
transcript | string | Transcript, once the job has completed |
segments | array | Speaker turns or sentence segments, when requested for the job |
language | string | BCP-47 code of the predominant spoken language |
failureReason | string | Why the job failed, when it failed |