Skip to main content
POST
/
v1
/
audio
/
speech
Generate speech audio
curl --request POST \
  --url https://api.tera.gw/v1/audio/speech \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "hexgrad/Kokoro-82M",
  "input": "<string>",
  "voice": "af_bella",
  "response_format": "wav",
  "speed": 1,
  "lang_code": "<string>"
}
'
"<string>"

Documentation Index

Fetch the complete documentation index at: https://docs.tera.gw/llms.txt

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

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
model
string
required
Example:

"hexgrad/Kokoro-82M"

input
string
required

Text to synthesize.

voice
string

Kokoro voice id.

Example:

"af_bella"

response_format
enum<string>
default:wav
Available options:
wav,
mp3
speed
number
default:1
Required range: 0.25 <= x <= 4
lang_code
string

BCP-47 language code, e.g. en-US.

Response

Audio bytes (WAV by default).

The response is of type file.