public class CreateTtsTaskRequest extends AbstractModel
header, skipSign| Constructor and Description | 
|---|
| CreateTtsTaskRequest() | 
| CreateTtsTaskRequest(CreateTtsTaskRequest source)NOTE: Any ambiguous key set via .set("AnyKey", "value") will be a shallow copy,
       and any explicit key, i.e Foo, set via .setFoo("value") will be a deep copy. | 
| Modifier and Type | Method and Description | 
|---|---|
| String | getCallbackUrl()Get 回调 URL,用户自行搭建的用于接收识别结果的服务URL。如果用户使用轮询方式获取识别结果,则无需提交该参数。[回调说明](https://cloud.tencent.com/document/product/1073/55746) | 
| String | getCodec()Get 返回音频格式,可取值:mp3(默认),wav,pcm | 
| String | getEmotionCategory()Get 控制合成音频的情感,仅支持多情感音色使用。取值: neutral(中性)、sad(悲伤)、happy(高兴)、angry(生气)、fear(恐惧)、news(新闻)、story(故事)、radio(广播)、poetry(诗歌)、call(客服)、sajiao(撒娇)、disgusted(厌恶)、amaze(震惊)、peaceful(平静)、exciting(兴奋)、aojiao(傲娇)、jieshuo(解说) | 
| Long | getEmotionIntensity()Get 控制合成音频情感程度,取值范围为[50,200],默认为100;只有EmotionCategory不为空时生效。 | 
| Boolean | getEnableSubtitle()Get 是否开启时间戳功能,默认为false。 | 
| Long | getModelType()Get 模型类型,1-默认模型。 | 
| Long | getPrimaryLanguage()Get 主语言类型:1-中文(默认)2-英文3-日文 | 
| Long | getProjectId()Get 项目id,用户自定义,默认为0。 | 
| Long | getSampleRate()Get 音频采样率:16000:16k(默认)8000:8k | 
| Float | getSpeed()Get 语速,范围:[-2,6],分别对应不同语速:-2代表0.6倍-1代表0.8倍0代表1.0倍(默认)1代表1.2倍2代表1.5倍6代表2.5倍如果需要更细化的语速,可以保留小数点后 2 位,例如0.5/1.25/2.81等。 参数值与实际语速转换,可参考[代码示例](https://sdk-1300466766.cos.ap-shanghai.myqcloud.com/sample/speed_sample.tar.gz) | 
| String | getText()Get 合成语音的源文本,按UTF-8编码统一计算,最多支持10万字符 | 
| Boolean | getVoiceoverDialogueSplit()Get 旁白与对白文本解析,分别合成相应风格(仅适用于旁对白音色10510000、100510000),默认 false | 
| Long | getVoiceType()Get 音色 ID,价格请参见[购买指南](https://cloud.tencent.com/document/product/1073/34112)。完整的音色 ID 列表请参见[音色列表](https://cloud.tencent.com/document/product/1073/92668)。 | 
| Float | getVolume()Get 音量大小,范围[-10,10],对应音量大小。默认为0,代表正常音量,值越大音量越高。 | 
| void | setCallbackUrl(String CallbackUrl)Set 回调 URL,用户自行搭建的用于接收识别结果的服务URL。如果用户使用轮询方式获取识别结果,则无需提交该参数。[回调说明](https://cloud.tencent.com/document/product/1073/55746) | 
| void | setCodec(String Codec)Set 返回音频格式,可取值:mp3(默认),wav,pcm | 
| void | setEmotionCategory(String EmotionCategory)Set 控制合成音频的情感,仅支持多情感音色使用。取值: neutral(中性)、sad(悲伤)、happy(高兴)、angry(生气)、fear(恐惧)、news(新闻)、story(故事)、radio(广播)、poetry(诗歌)、call(客服)、sajiao(撒娇)、disgusted(厌恶)、amaze(震惊)、peaceful(平静)、exciting(兴奋)、aojiao(傲娇)、jieshuo(解说) | 
| void | setEmotionIntensity(Long EmotionIntensity)Set 控制合成音频情感程度,取值范围为[50,200],默认为100;只有EmotionCategory不为空时生效。 | 
| void | setEnableSubtitle(Boolean EnableSubtitle)Set 是否开启时间戳功能,默认为false。 | 
| void | setModelType(Long ModelType)Set 模型类型,1-默认模型。 | 
| void | setPrimaryLanguage(Long PrimaryLanguage)Set 主语言类型:1-中文(默认)2-英文3-日文 | 
| void | setProjectId(Long ProjectId)Set 项目id,用户自定义,默认为0。 | 
| void | setSampleRate(Long SampleRate)Set 音频采样率:16000:16k(默认)8000:8k | 
| void | setSpeed(Float Speed)Set 语速,范围:[-2,6],分别对应不同语速:-2代表0.6倍-1代表0.8倍0代表1.0倍(默认)1代表1.2倍2代表1.5倍6代表2.5倍如果需要更细化的语速,可以保留小数点后 2 位,例如0.5/1.25/2.81等。 参数值与实际语速转换,可参考[代码示例](https://sdk-1300466766.cos.ap-shanghai.myqcloud.com/sample/speed_sample.tar.gz) | 
| void | setText(String Text)Set 合成语音的源文本,按UTF-8编码统一计算,最多支持10万字符 | 
| void | setVoiceoverDialogueSplit(Boolean VoiceoverDialogueSplit)Set 旁白与对白文本解析,分别合成相应风格(仅适用于旁对白音色10510000、100510000),默认 false | 
| void | setVoiceType(Long VoiceType)Set 音色 ID,价格请参见[购买指南](https://cloud.tencent.com/document/product/1073/34112)。完整的音色 ID 列表请参见[音色列表](https://cloud.tencent.com/document/product/1073/92668)。 | 
| void | setVolume(Float Volume)Set 音量大小,范围[-10,10],对应音量大小。默认为0,代表正常音量,值越大音量越高。 | 
| void | toMap(HashMap<String,String> map,
     String prefix)Internal implementation, normal users should not use it. | 
any, fromJsonString, getBinaryParams, GetHeader, getMultipartRequestParams, getSkipSign, isStream, set, SetHeader, setParamArrayObj, setParamArraySimple, setParamObj, setParamSimple, setSkipSign, toJsonStringpublic CreateTtsTaskRequest()
public CreateTtsTaskRequest(CreateTtsTaskRequest source)
public String getText()
public void setText(String Text)
Text - 合成语音的源文本,按UTF-8编码统一计算,最多支持10万字符public Float getVolume()
public void setVolume(Float Volume)
Volume - 音量大小,范围[-10,10],对应音量大小。默认为0,代表正常音量,值越大音量越高。public Float getSpeed()
public void setSpeed(Float Speed)
Speed - 语速,范围:[-2,6],分别对应不同语速:public Long getProjectId()
public void setProjectId(Long ProjectId)
ProjectId - 项目id,用户自定义,默认为0。public Long getModelType()
public void setModelType(Long ModelType)
ModelType - 模型类型,1-默认模型。public Long getVoiceType()
public void setVoiceType(Long VoiceType)
VoiceType - 音色 ID,价格请参见[购买指南](https://cloud.tencent.com/document/product/1073/34112)。完整的音色 ID 列表请参见[音色列表](https://cloud.tencent.com/document/product/1073/92668)。public Long getPrimaryLanguage()
public void setPrimaryLanguage(Long PrimaryLanguage)
PrimaryLanguage - 主语言类型:public Long getSampleRate()
public void setSampleRate(Long SampleRate)
SampleRate - 音频采样率:public String getCodec()
public void setCodec(String Codec)
Codec - 返回音频格式,可取值:mp3(默认),wav,pcmpublic String getCallbackUrl()
public void setCallbackUrl(String CallbackUrl)
CallbackUrl - 回调 URL,用户自行搭建的用于接收识别结果的服务URL。如果用户使用轮询方式获取识别结果,则无需提交该参数。[回调说明](https://cloud.tencent.com/document/product/1073/55746)public Boolean getEnableSubtitle()
public void setEnableSubtitle(Boolean EnableSubtitle)
EnableSubtitle - 是否开启时间戳功能,默认为false。public Boolean getVoiceoverDialogueSplit()
public void setVoiceoverDialogueSplit(Boolean VoiceoverDialogueSplit)
VoiceoverDialogueSplit - 旁白与对白文本解析,分别合成相应风格(仅适用于旁对白音色10510000、100510000),默认 falsepublic String getEmotionCategory()
public void setEmotionCategory(String EmotionCategory)
EmotionCategory - 控制合成音频的情感,仅支持多情感音色使用。取值: neutral(中性)、sad(悲伤)、happy(高兴)、angry(生气)、fear(恐惧)、news(新闻)、story(故事)、radio(广播)、poetry(诗歌)、call(客服)、sajiao(撒娇)、disgusted(厌恶)、amaze(震惊)、peaceful(平静)、exciting(兴奋)、aojiao(傲娇)、jieshuo(解说)public Long getEmotionIntensity()
public void setEmotionIntensity(Long EmotionIntensity)
EmotionIntensity - 控制合成音频情感程度,取值范围为[50,200],默认为100;只有EmotionCategory不为空时生效。Copyright © 2025. All rights reserved.