Skip to Content
Quickstart

Quickstart

Make your first TTS and STT call in under 10 minutes.

1. Create an API key

Go to the API Keys page in your Revolab dashboard and click Create key. Copy the key — you will not be able to see it again.

2. Set the REVOLAB_API_KEY environment variable

export REVOLAB_API_KEY="rvl_live_..."

3. Make your first TTS call

Send a POST /v1/tts request with your text. Replace <your-voice-id> with a voice from the Voice Library in your dashboard — or list them programmatically with GET /v1/voices. The response body is the generated WAV audio itself; duration and latency arrive as headers.

curl -X POST https://api.revolab.ai/v1/tts \ -H "Authorization: Bearer $REVOLAB_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "nada-1.0-flash", "text": "Hello, world! This is my first Revolab TTS call.", "voice_id": "<your-voice-id>", "language": "en" }' \ -o speech.wav

Expected result: speech.wav on disk, with X-Duration-S / X-Latency-Ms response headers carrying the generation metrics.

4. Make your first STT call

Upload an audio file (WAV, MP3, M4A, FLAC, OGG, Opus, or WebM; max 50 MB, max 30 minutes) to POST /v1/stt. The response contains the transcript and detected language.

# Transcribe a local audio file curl -X POST https://api.revolab.ai/v1/stt \ -H "Authorization: Bearer $REVOLAB_API_KEY" \ -F "file=@/path/to/audio.wav" \ -F "model=aisyah-1.0-flash" \ -F "language=en" | python3 -c " import sys, json data = json.load(sys.stdin) print('Transcript:', data['text']) print('Language:', data['language']) print('Duration:', data['duration_s'], 's') "

Expected response: {"text":"Hello world","language":"en","duration_s":1.8,"confidence":0.98,"latency_ms":520}

5. Where to go next

  • TTS API reference — all parameters, models, voices, speed control, output formats.
  • STT API reference — all parameters, file constraints, language detection.
  • Error catalog — every error.code with causes and fixes.
  • Models — five models, latency vs quality trade-offs.
  • Compatible APIs — already using the OpenAI, ElevenLabs, or Cartesia SDK? Keep it and just change the base URL.