Developers / Text to Speech

Generate speech from text

POST https://api.echonova.ai/v1/text-to-speech

Starts a Text to Speech job for 1 to 500 characters and returns its jobId. Get the audio from GET /v1/text-to-speech/jobs/{jobId} or the job.completed webhook. Cloned voices work with the sync endpoint only.

Headers

Authorization string Required

Bearer, a space, then your API key, which starts with ek_. Create keys in the portal under Developers, API Keys.

Request body

application/json

text string Required

The text to speak, 1 to 500 characters. Leading and trailing whitespace is trimmed.

1 to 500 characters
voiceId string Required

The id of a voice from List available voices. The voice fixes the dialect.

speed number Optional

How fast the voice speaks.

0.5 to 2default 1
cfg number Optional

How closely the voice follows the text. Leave it at the default unless you are tuning.

1 to 5default 2
numSteps number Optional

Diffusion steps. More steps are slower and cleaner.

16, 32, 48, 64 or 128default 48
tashkeel boolean Optional

Adds the vowel marks to Arabic text before it is read. Applies to Fusha voices only.

default false
normalize boolean Optional

Reads numbers, dates, times, money, units, URLs and e-mails the way a speaker of the voice's dialect says them. On unless you send false.

default true

Response

200 application/json Every response uses this envelope.

data object

The result.

success boolean

true for a successful call.

statusCode integer

Repeats the HTTP status.

errorMessage string or null

null on success.

Errors

Same envelope, with success false and data null. All errors

POST /v1/text-to-speech

curl -X POST "https://api.echonova.ai/v1/text-to-speech" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"text":"الطقس اليوم جميل والسماء صافية في المدينة","voiceId":"66e5ef3a9c1d2b4f8a7e6c01"}'

{
  "data": {
    "jobId": "66e5f0c2a1b2c3d4e5f60718",
    "status": "processing"
  },
  "success": true,
  "statusCode": 200,
  "errorMessage": null
}