Run in Apifox
Price: 40 PTC/million characters Request Body Params application/json
{
"audioConfig" : {
"audioEncoding" : "LINEAR16" ,
"effectsProfileId" : [
"headphone-class-device"
] ,
"pitch" : 0 ,
"speakingRate" : 0.96
} ,
"input" : {
"text" : "302 is truly an awesome platform."
} ,
"voice" : {
"languageCode" : "cmn-CN" ,
"name" : "cmn-CN-Chirp3-HD-Schedar"
}
}
Request Code Samples
curl --location --request POST 'https://api.302.ai/google/v1/text-synthesize?response_format=url' \
--header 'Authorization: Bearer sk-jls4AaVBGoe1GwZD64qZA1qyKTN1MPHa4NmvH1cT68z7K1Zz' \
--header 'Content-Type: application/json' \
--data-raw '{
"audioConfig": {
"audioEncoding": "LINEAR16",
"effectsProfileId": [
"headphone-class-device"
],
"pitch": 0,
"speakingRate": 0.96
},
"input": {
"text": "302 is truly an awesome platform."
},
"voice": {
"languageCode": "cmn-CN",
"name": "cmn-CN-Chirp3-HD-Schedar"
}
}'
Responses application/json Generate Code
{
"audioConfig" : {
"audioEncoding" : "LINEAR16" ,
"effectsProfileId" : [ ] ,
"pitch" : 0 ,
"sampleRateHertz" : 24000 ,
"speakingRate" : 0.96 ,
"volumeGainDb" : 0
} ,
"audioContent" : "https://file.302.ai/gpt/imgs/20250617/671b1957ba22428abf0a1c9fb9f25241.mp3" ,
"timepoints" : [ ]
}
Modified at 2025-06-18 06:53:33