Skip to main content
Want to try TTS without setting up code? Open the live demo and test different models and voices in your browser.
These examples use the Deepgram Aura model; swap the endpoint path to use a different provider.

Placeholders

The snippets below use these placeholders. Replace them before running the code.
PlaceholderReplace with
SLNG_API_KEYAn SLNG key from app.slng.ai/api-keys

Basic Request

Send text and receive a complete audio file in WAV format:
curl https://api.slng.ai/v1/tts/slng/deepgram/aura:2-en \
  -H "Authorization: Bearer SLNG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "aura-2-thalia-en",
    "text": "Hello from sunny Barcelona!"
  }' \
  --output hello.wav
It will sound like this:

More Examples

With Voice Selection (Deepgram Aura)

Beyond the audio generation, each model supports different parameters. For example, to specify a voice in Deepgram Aura:
curl https://api.slng.ai/v1/tts/slng/deepgram/aura:2-en \
  -H "Authorization: Bearer SLNG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "Hello from sunny Barcelona!",
    "model": "aura-2-theia-en"
  }' \
  --output hello-theia.wav
For the complete parameter reference, see the Text-to-Speech API reference.

With a Different Model

Each model has its own endpoint and may use different parameters. For example, Rime Arcana uses speaker instead of model:
curl https://api.slng.ai/v1/tts/slng/rime/arcana:3-en \
  -H "Authorization: Bearer SLNG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "Hello from Rime Arcana!",
    "speaker": "astra"
  }' \
  --output hello-arcana.wav
For all available models, endpoints, and their parameters, see the TTS models page. To control how brand names, acronyms, and domain-specific terms are spoken, add a pronunciation dictionary to your TTS request. For voice catalogs with audio samples, browse the Voices section in the sidebar.

Next Steps

Live TTS demo

Try TTS in your browser, no setup needed

TTS WebSocket examples

Stream audio in real time for voice agents

Text-to-Speech models

Browse all TTS models and endpoints

Pronunciation dictionaries

Reuse pronunciation rules across TTS requests

TTS API reference

Endpoint-specific parameters