tencent cloud

DokumentasiMedia Processing Service

TTS

Unduh
Mode fokus
Ukuran font
Terakhir diperbarui: 2026-10-27 15:57:07
Diterjemahkan oleh AI

Feature Introduction

It offers a variety of AI voice models, making it widely applicable to scenarios such as audiobooks, podcasts, and audio/video creation. It supports 40+ languages, including Chinese, English, Japanese, and Korean, and provides a rich set of system voices with high-fidelity voice cloning.


Prerequisites

Before using this feature, you need to complete the following preliminary operations:
Register or log in to a Tencent Cloud account, activate MPS, and complete the service role authorization.
If you use a Tencent Cloud sub-account, ensure the account has sufficient permissions to use MPS.
For detailed guidance, see Getting Started. For account authorization issues, see the Account Authorization document.

Billing Overview

TTS fees are charged. For detailed pricing, see the Billing Description document.

Initiating a TTS Task

Short Text TTS (Synchronous)

Console entry: AIGC Task Creation > AI Voice.

You can also call the Synchronous TTS API to initiate a task and obtain the result.
Input example:
{
"Text": "Hello"
"VoiceId": "s1_iX4D1zb9hyem/Bp2GpyJ7cD0miMrFVWDbtKap71N8cF8M7raq9RAupL+bRWn"
}
Output example:
{
"Response": {
"AudioData": "UklGRk5kAABXQVZFZm10IBAAAA....",
"ErrorCode": 0,
"ExtInfo": "{\\"duration\\":0.766313,\\"chars\\":4}",
"Msg": "success",
"RequestId": "49c07248-6c7d-4530-be07-9c66251e52e3",
"AudioUrl": "https://*********************.cos.accelerate.myqcloud.com/speech/23cb48a7-d5e8-4f60-b30f-6fffe599c8e7.wav"
}
}

Long Text TTS (Asynchronous)

Call the Asynchronous TTS API to initiate a task.
Input example:
{
"Text": "Hello"
"VoiceId": "s1_iX4D1zb9hyem/Bp2GpyJ7cD0miMrFVWDbtKap71N8cF8M7raq9RAupL+bRWn"
}
Output example:
{
"Response": {
"ErrorCode": 0,
"Msg": "success",
"TaskId": "1300057393-DubbingAsync-0d810bb0-d78b-4545-b36e-eab983b40a6a",
"RequestId": "0d810bb0-d78b-4545-b36e-eab983b40a6a"
}
}
Call the Query TTS Task Result API to query the task result.
Input example:
{
"TaskId": "1300057393-DubbingAsync-fc3f52cf-f5f2-453c-882c-8847e5b2fe2f"
}
Output example:
{
"Response": {
"AudioUrl": "https://laurie-tmp-1300828900.cos.ap-nanjing.myqcloud.com/async_dubbing/fc3f52cf-f5f2-453c-882c-8847e5b2fe2f.wav",
"ErrorCode": 0,
"ExtInfo": "{\\"duration\\":1.00325}",
"Msg": "success",
"Status": "success",
"VoiceId": "s1_+DSBRZuGbfKlwsN1lV5OsriSYvOB3aSqqCsHH0LJ5BWHsmfmn13my4ki/QL+g+7RaRUWLhwPcEI6gtCTkA==",
"RequestId": "c63e8ebb-af80-4987-b65e-eda61ac74455"
}
}

Specifying the Engine and Model Version

MPS TTS supports a wide range of engines and model versions, including:
Engine
Model Version
Feature
MiniMax
speech-2.8-hd, speech-2.8-turbo, speech-2.6-hd, speech-02-hd, speech-2.6-turbo, speech-02-turbo, and more.
Balanced capabilities and long text support. Suitable for scenarios such as audiobooks, Chinese content factories, and digital human conversations.
TTS-F
-
Strong fine-grained emotion control. Suitable for scenarios such as multi-role narration and emotional performances.
Note:
For a complete list, contact us.
This tutorial provides guidance on integrating the MiniMax engine. For guidance on integrating other engines, contact us.
When contacting us, provide necessary information such as the use case and usage volume for evaluation.

MiniMax

Specify the engine and corresponding parameters through the extension ExtParam.
Extended Parameters and Descriptions
Parameter
Type
Required
Description
engine
String
Yes
Fill in minimax.
synExt
Object
No
TTS extended parameters
synExt.model
String
No
Specifies the model. Supported values include speech-2.6-hd and speech-2.8-hd (default).
synExt.emotion
String
No
Controls the emotion of the synthesized speech. The parameter value range is ["happy", "sad", "angry", "fearful", "disgusted", "surprised", "calm"], corresponding to seven emotions: happy, sad, angry, fearful, disgusted, surprised, and neutral.
synExt.format
String
No
Audio format. Optional values: wav and mp3. Default value: wav.
synExt.sampleRate
Integer
No
Sample rate of the synthesized audio. Optional values: [8000, 16000, 22050, 24000, 32000, 44100]. Default value: 16000.
synExt.duration
Float
No
Specifies the audio duration.
synExt.speed
Float
No
Speech rate. Value range: [0.5, 2]. Default value: 1.0.
synExt.vol
Float
No
Volume. Value range: (0, 10]. Default value: 1.0.
synExt.pitch
Integer
No
Pitch. Value range: [-12, 12]. Default value: 0, which indicates the original pitch.
synExt.cutSilence
Bool
No
Whether to remove silence at both ends. Currently, only Chinese and English are supported.
synExt.engineCustom
Object
No
Engine customization parameters. Supports pass-through of all official request parameters of the TTS engine. If the same parameter is specified at both the outer layer and inner layer, the outer layer takes precedence.
ExtParam Extended Parameter Example
{
"engine": "minimax",
"synExt": {
"model": "speech-2.6-hd",
"emotion": "happy",
"speed": 0.9,
"engineCustom": {
"pronunciation_dict": {
"tone": [
"Processing/(chu3)(li3)"
"Tokyo/Tokyo"
]
},
"subtitle_enable": false
}
}
}
MiniMax TTS Example
{
"Text": "Hello"
"VoiceId": "Chinese (Mandarin)_News_Anchor",
"ExtParam": "{\\"engine\\":\\"minimax\\",\\"synExt\\":{\\"model\\":\\"speech-2.6-hd\\",\\"emotion\\":\\"happy\\",\\"speed\\":0.9}}"
}

Querying Available Voices

The System Voice List document lists some commonly used system voices. You can also go to the Console Voice Library to view the complete voice list.

The API is Query Available Voices. To query available voices for a specific engine, pass in engine through ExtParam.
Parameter
Type
Required
Description
engine
String
Required when ExtParam is passed.
Specifies the engine name.
Example of querying available MiniMax voices:
{
"ExtParam": "{\\"engine\\":\\"minimax\\"}"
}

Appendix: Supported Languages

Different engines and model versions support different languages. The following is a list of some common languages:
Supported Languages
Language Code (Supported Options for srcLang and cloneVideoLang Parameters)
Chinese
zh
English
en
Japanese
ja
German
de
French
fr
Korean
ko
Russian
ru
Ukrainian
uk
Portuguese
pt
Italian
it
Spanish
es
Indonesian
id
Dutch
nl
Turkish
tr
Filipino
fil
Malay
ms
Greek
el
Finnish
fi
Croatian
hr
Slovak
sk
Polish
pl
Swedish
sv
Hindi
hi
Bulgarian
bg
Romanian
ro
Arabic
ar
Czech
cs
Danish
da
Tamil
ta
Hungarian
hun
Vietnamese
vi
Norwegian
no
Cantonese
yue
Thai
th
Hebrew
he
Catalan
ca
Nynorsk
nn
Afrikaans
af
Persian
fa
Slovenian
sl

Bantuan dan Dukungan

Apakah halaman ini membantu?

masukan