Skip to main content
Endpoint: POST https://fal.run/xai/tts/v1 Endpoint ID: xai/tts/v1

Try it in the Playground

Run this model interactively with your own prompts.

Quick Start

import fal_client

def on_queue_update(update):
    if isinstance(update, fal_client.InProgress):
        for log in update.logs:
           print(log["message"])

result = fal_client.subscribe(
    "xai/tts/v1",
    arguments={
        "text": "Hello! This is xAI text to speech, brought to you by Fal AI."
    },
    with_logs=True,
    on_queue_update=on_queue_update,
)
print(result)

Input Schema

text
string
required
The text to convert to speech. Maximum 15,000 characters. Supports speech tags for expressive delivery: inline tags like [laugh], [pause], [sigh] and wrapping tags like <whisper>text</whisper>, <slow>text</slow>.
voice
VoiceEnum
default:"eve"
Voice to use for synthesis. eve: energetic, upbeat. ara: warm, friendly. rex: confident, clear. sal: smooth, balanced. leo: authoritative, strong. Default value: "eve"Possible values: eve, ara, rex, sal, leo
language
LanguageEnum
default:"auto"
BCP-47 language code or ‘auto’ for automatic detection. Supported: en, zh, fr, de, hi, id, it, ja, ko, pt-BR, pt-PT, ru, es-MX, es-ES, tr, vi, bn, ar-EG, ar-SA, ar-AE. Default value: "auto"Possible values: auto, en, ar-EG, ar-SA, ar-AE, bn, zh, fr, de, hi, id, it, ja, ko, pt-BR, pt-PT, ru, es-MX, es-ES, tr, vi
output_format
OutputFormat
Output format configuration. Defaults to MP3 at 24 kHz / 128 kbps.

Output Schema

audio
File
required
The generated audio file.

Input Example

{
  "text": "Hello! This is xAI text to speech, brought to you by Fal AI.",
  "voice": "eve",
  "language": "auto"
}

Output Example

{
  "audio": {
    "url": "https://v3b.fal.media/files/b/0a92750b/exZJCm6TDejS5xIulJs2r_xai_tts_output.mp3"
  }
}

Limitations

  • voice restricted to: eve, ara, rex, sal, leo