Skip to main content
POST

Billing

Billed in USD per million input characters. Current prices are listed on the Modellix Pricing Page.
  • Single speaker: Count Unicode characters in text.
  • Two speakers: Sum Unicode characters in all turns[].text, without adding separators.
  • style, speaker names, voice names, and language_code are excluded from the character count.

Authorizations

Authorization
string
header
required

Modellix API Key. Format: Bearer <your_api_key>

Body

application/json

Use text and voice for single-speaker synthesis, or speakers and turns for two-speaker dialogue. Dialogue requests must omit top-level text, voice, and style. Combined text and trimmed style must not exceed 8,192 Unicode characters.

text
string

Verbatim transcript. Required for single-speaker synthesis.

Required string length: 1 - 8192
Example:

"Have a wonderful day!"

style
string

Optional delivery direction for single-speaker synthesis. Not spoken aloud.

Maximum string length: 8192
Example:

"cheerful and friendly"

language_code
string

Optional BCP-47 language tag in lowercase. Examples: en-us, cmn-cn, ja-jp. The model can also detect the language from the transcript.

Pattern: ^[a-z]{2,3}(-[a-z0-9]+)*$
Example:

"en-us"

voice
string

Required for single-speaker synthesis. Prebuilt voice name, extended voice-library ID, or a designed/replicated voice ID (voice_... or voicekey_...). No spaces.

Required string length: 1 - 256
Example:

"Kore"

speakers
object[]

Exactly two speakers for dialogue. Use with turns.

Required array length: 2 elements
turns
object[]

Dialogue turns in order. Each speaker must match a name in speakers, case-sensitively.

Minimum array length: 1

Response

Task submitted successfully. Poll GET /api/v1/tasks/{task_id} until the task completes; synthesized audio is returned on the task result.

code
integer
required

Response code, 0 indicates success

Example:

0

message
string
required

Response message

Example:

"success"

data
object
required

Task submission details. Poll GET /api/v1/tasks/{task_id} until status is success; audio appears in result.resources with type audio and format wav.