
General Interface
API Overview
Enable the invocation of all TTS (Text-to-Speech) models through a unified format.
API Console
Log in to explore more features! Click to Log In
API Reference (3)
| API Description | API Endpoint | Request Method | Stability | Parameter Description |
|---|---|---|---|---|
Text-to-Speech Generation(302 Format) | POST | Stable | View Details | |
Document Details Pricing: Charged according to the corresponding TTS provider Request Parameters Header ParametersAuthorizationstringRequired Example Value: Bearer {{YOUR_API_KEY}}Request Body application/jsontextstringRequired providerenum<string>Required Can be accessed from /302/tts/provider Enum Value: openaidoubaoazurefishminimaxidubbingxelevenlabselevenlabs-officialmerukagoogleqwenmodelstringOptional Some vendors require this parameter. You can determine whether model data needs to be provided based on the results from the /302/tts/provider endpoint. voicestringRequired speednumberOptional Some vendors do not support the speech rate parameter. volumenumberOptional Some vendors do not support volume adjustment. emotionstringOptional Effective for some providers. You can determine whether the emotion parameter is effective from the result of the /302/tts/provider API. output_formatstringOptional Effective for some providers. You can determine whether this parameter is effective for the corresponding provider from the results of the /302/tts/provider endpoint. timeoutintegerOptional | ||||
Query TTS Provider Information | GET | Stable | View Details | |
Request Parameters Header ParametersAuthorizationstringRequired Example Value: Bearer {{YOUR_API_KEY}}Query ParametersproviderstringOptional Example Value: doubao | ||||
TTS Text-to-Speech Generation(openai Format) | POST | Stable | View Details | |
Document Details Model/Voice List & Parameter Description: Pricing: Charged according to the corresponding TTS provider openai SDK Usage Example
Request Parameters Header ParametersAuthorizationstringRequired Example Value: Bearer {{YOUR_API_KEY}}Request Body application/jsoninputstringRequired modelstringRequired voicestringRequired instructionsstringOptional response_formatenum<string>Optional Enum Value: mp3opusaacflacwavpcmspeednumberOptional Not all models are supported; please refer to the parameter documentation for details. stream_formatenum<string>Optional SSE response is not supported yet Enum Value: audiourlvolumenumberOptional Not all models are supported; please refer to the parameter documentation for details. | ||||
API Pricing
| Model | Description | 302.AI Price |
|---|
Text-to-Speech Generation(302 Format) | Text-to-Speech Generation(302 Format) |
|
TTS Text-to-Speech Generation((openai Format) | TTS Text-to-Speech Generation(openai Format) |
|
Query TTS Provider Information | Text-to-Speech Generation |
InputFree OutputFree Original Price |