Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.tryhamsa.com/llms.txt

Use this file to discover all available pages before exploring further.

Hamsa Text to Speech (TTS) converts written text into natural-sounding audio with proper Arabic pronunciation, intonation, and support for multiple dialects. Whether you’re creating media content, building voice applications, or making content accessible, Hamsa TTS delivers high-quality Arabic speech synthesis.

Overview

API Reference

Technical API documentation for developers

Quickstart

Get started with TTS in minutes

Key features

Arabic dialect support

Hamsa TTS supports a wide range of Arabic dialects:
  • Multiple dialects: Egyptian, Gulf, Levantine, Iraqi, and Modern Standard Arabic
  • Natural pronunciation: Proper handling of Arabic phonetics and pronunciation rules
  • Code-switching: Handling of mixed Arabic-English text
  • Diacritical marks: Support for tashkeel and proper pronunciation

High-quality voices

  • Pre-built Arabic voices optimized for different dialects
  • Custom voice cloning for brand consistency
  • Gender and age variety

Flexible integration

API endpoints

Hamsa provides two TTS endpoints for different use cases:

Jobs API

Async — /v1/jobs/text-to-speechInitiates a TTS job and delivers the result via webhook. Best for batch processing and media content generation.Parameters: text, voiceId, webhookUrl

Realtime API

Sync — /v1/realtime/ttsReturns WAV audio directly in the response. Best for real-time voice agents and interactive applications.Parameters: text, speaker, dialect, mulaw

Supported dialects

CodeDialectExample voices
plsPalestinianAmjad, Layan
egyEgyptianMariam, Samir
syrSyrianDalal, Mais
irqIraqiLyali, Fatma
jorJordanianLana, Jasem
lebLebaneseCarla, Majd
ksaSaudiHiba, Fahd
uaeEmiratiSalma, Dima
bahBahrainiMazen, Ruba
qatQatariDeema, Faisal
kuwKuwaitiMai, Hatem
omaOmaniAisha, Jaber
msaModern Standard ArabicSalem, Tamim
ar-saArabic – GulfKhalid, Rahma
enEnglishEmma, James

Getting started

1

Choose your integration

Use the Realtime API for direct audio, the Jobs API for async processing, or the Media Platform web interface.
2

Select a voice and dialect

Choose a voice and dialect that matches your target audience from the table above.
3

Generate audio

Call the API with your text and voice selection. See the Quickstart for examples.

Next steps

Quickstart Guide

Build your first TTS integration

Voice Options

Explore available voices

Voice Cloning

Learn about custom voice cloning

Media Platform

Use TTS via web interface

FAQ

The Jobs API (/v1/jobs/text-to-speech) is async — it creates a job and delivers the audio via webhook. Use it for batch processing. The Realtime API (/v1/realtime/tts) returns WAV audio directly in the response — use it for real-time applications and voice agents.
Yes, Hamsa TTS handles code-switching between Arabic and English.
Choose the dialect that matches your target audience. Egyptian Arabic has wide recognition across the Arab world. Gulf dialects are preferred in GCC countries. Levantine is common in the Levant region. For formal content, use Modern Standard Arabic (MSA).
Yes, Hamsa supports custom voice cloning. See the voice cloning guide for details.
The Realtime API returns WAV audio by default. You can enable μ-law encoding via the mulaw parameter for telephony use cases.