全部接口
获取file
查询语音生成任务状态
创建异步语音合成任务
同步语音合成
OpenAI TTS 格式
模型信息
| 模型 ID | minimax/speech-2.8-hd | 供应商 | Minimax |
|---|---|---|---|
| 输入模态 | text | 输出模态 | text、audio |
| 分类 | audio | 发布时间 | 2026-09-23 13:26:00 |
调用接口
| 分组 | 接口 | 渠道 | 方法 | 路径 |
|---|---|---|---|---|
| 同步语音合成 | 同步语音合成 | 本站 AI 中转站 | POST | /minimax/v1/t2a_v2 |
POST /minimax/v1/t2a_v2
### 同步语音合成
[官方文档](
通过提交 post请求{{BASE_URL}}/minimaxi/v1/voice_design
并同步得到结果
{
"summary": "同步语音合成",
"responses": {
"200": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"data": {
"type": "object",
"properties": {
"audio": {
"type": "string",
"description": "合成后的音频数据,采用 hex 编码,格式与请求中指定的输出格式一致"
},
"status": {
"type": "integer",
"description": "当前音频流状态:1 表示合成中,2 表示合成结束"
},
"subtitle_file": {
"type": "string",
"description": "合成的字幕下载链接。音频文件对应的字幕,精确到句(不超过 50 字),单位为毫秒,格式为 json"
}
},
"description": "返回的合成数据对象,可能为 null,需进行非空判断"
},
"trace_id": {
"type": "string"
},
"base_resp": {
"type": "object",
"required": [
"status_code",
"status_msg"
],
"properties": {
"status_msg": {
"type": "string",
"description": "状态详情"
},
"status_code": {
"type": "integer",
"description": "状态码。\n\n0: 请求结果正常\n1000: 未知错误\n1001: 超时\n1002: 触发限流\n1004: 鉴权失败\n1039: 触发 TPM 限流\n1042: 非法字符超过 10%\n2013: 输入参数信息不正常"
}
}
},
"extra_info": {
"type": "object",
"properties": {
"bitrate": {
"type": "integer",
"description": "音频比特率"
},
"audio_size": {
"type": "integer",
"description": "音频文件大小(字节)"
},
"word_count": {
"type": "integer",
"description": "已发音的字数统计,包含汉字、数字、字母,不包含标点符号"
},
"audio_format": {
"type": "string",
"description": "生成音频文件的格式。取值范围 [mp3, pcm, flac]"
},
"audio_length": {
"type": "integer",
"description": "音频时长(毫秒)"
},
"audio_channel": {
"type": "integer",
"description": "生成音频声道数,1:单声道,2:双声道"
},
"usage_characters": {
"type": "integer",
"description": "计费字符数"
},
"audio_sample_rate": {
"type": "integer",
"description": "音频采样率"
},
"invisible_character_ratio": {
"type": "integer",
"description": "非法字符占比.非法字符不超过 10%(包含 10%),音频会正常生成,并返回非法字符占比数据;如超过 10% 将进行报错"
}
}
}
}
}
}
},
"description": "成功"
}
},
"parameters": [],
"description": "### 同步语音合成\n[官方文档](\n\n通过提交 post请求{{BASE_URL}}/minimaxi/v1/voice_design\n并同步得到结果",
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"title": "同步语音合成",
"$schema": "",
"required": [
"model",
"text",
"voice_setting"
],
"properties": {
"text": {
"type": "string",
"description": "需要合成语音的文本"
},
"model": {
"type": "string",
"description": "请求的模型版本,可选范围:speech-2.6-hd, speech-2.6-turbo, speech-02-hd, speech-02-turbo, speech-01-hd, speech-01-turbo."
},
"stream": {
"type": "boolean",
"description": "控制是否流式输出。默认 false,即不开启流式"
},
"voice_modify": {
"type": "object",
"properties": {
"pitch": {
"type": "integer",
"description": "音高调整(低沉/明亮),范围 [-100,100],数值接近 -100,声音更低沉;接近 100,声音更明亮"
},
"timbre": {
"type": "integer",
"description": "音色调整(磁性/清脆),范围 [-100,100],数值接近 -100,声音更浑厚;数值接近 100,声音更清脆"
},
"intensity": {
"type": "integer",
"description": "强度调整(力量感/柔和),范围 [-100,100],数值接近 -100,声音更刚劲;接近 100,声音更轻柔"
},
"sound_effects": {
"type": "string",
"description": "音效设置,单次仅能选择一种,可选值:\n\nspacious_echo(空旷回音)\nauditorium_echo(礼堂广播)\nlofi_telephone(电话失真)\nrobotic(电音)\n可用选项: spacious_echo, auditorium_echo, lofi_telephone, robotic"
}
},
"description": "声音效果器设置,该参数支持的音频格式:\n\n非流式:mp3, wav, flac\n流式:mp3"
},
"audio_setting": {
"type": "object",
"properties": {
"format": {
"type": "string",
"description": "生成音频的格式,wav 仅在非流式输出下支持\n\n可用选项: mp3, pcm, flac, wav"
},
"bitrate": {
"type": "integer",
"description": "生成音频的比特率。可选范围[32000,64000,128000,256000],默认值为 128000。该参数仅对 mp3 格式的音频生效"
},
"channel": {
"type": "integer",
"description": "生成音频的声道数。可选范围:[1,2],其中 1 为单声道,2 为双声道,默认值为 1"
},
"force_cbr": {
"type": "boolean",
"description": "对于音频恒定比特率(cbr)控制,可选 false、 true。当此参数设置为 true,将以恒定比特率方式进行音频编码。\n注意:本参数仅当音频设置为流式输出,且音频格式为 mp3 时生效。"
},
"sample_rate": {
"type": "integer",
"description": "生成音频的采样率。可选范围[8000,16000,22050,24000,32000,44100],默认为 32000"
}
}
},
"output_format": {
"type": "string",
"description": "控制输出结果形式的参数,可选值范围为[url, hex],默认值为 hex 。该参数仅在非流式场景生效,流式场景仅支持返回 hex 形式。返回的 url 有效期为 24 小时\n\n可用选项: url, hex"
},
"voice_setting": {
"type": "object",
"required": [
"voice_id"
],
"properties": {
"vol": {
"type": "number",
"description": "合成音频的音量,取值越大,音量越高。取值范围 (0,10],默认值为 1.0"
},
"pitch": {
"type": "integer",
"description": "合成音频的语调,取值范围 [-12,12],默认值为 0,其中 0 为原音色输出"
},
"speed": {
"type": "number",
"description": "合成音频的语速,取值越大,语速越快。取值范围 [0.5,2],默认值为1.0"
},
"emotion": {
"type": "string",
"description": "控制合成语音的情绪,参数范围 [\"happy\", \"sad\", \"angry\", \"fearful\", \"disgusted\", \"surprised\", \"calm\", \"fluent\"],分别对应 8 种情绪:高兴,悲伤,愤怒,害怕,厌恶,惊讶,中性,生动\n\n模型会根据输入文本自动匹配合适的情绪,一般无需手动指定\n该参数仅对 speech-2.6-hd, speech-2.6-turbo, speech-02-hd, speech-02-turbo, speech-01-hd, speech-01-turbo 模型生效\n选项 fluent 仅对 speech-2.6-turbo, speech-2.6-hd 模型生效\n可用选项: happy, sad, angry, fearful, disgusted, surprised, calm, fluent"
},
"voice_id": {
"type": "string"
},
"latex_read": {
"type": "boolean",
"description": "控制是否朗读 latex 公式,默认为 false"
},
"text_normalization": {
"type": "boolean",
"description": "是否启用中文、英语文本规范化,开启后可提升数字阅读场景的性能,但会略微增加延迟,默认值为 false"
}
}
},
"aigc_watermark": {
"type": "boolean",
"description": "控制在合成音频的末尾添加音频节奏标识,默认值为 False。该参数仅对非流式合成生效"
},
"language_boost": {
"type": "string",
"description": "是否增强对指定的小语种和方言的识别能力。默认值为 null,可设置为 auto 让模型自主判断。\n\n可用选项: Chinese, Chinese,Yue, English, Arabic, Russian, Spanish, French, Portuguese, German, Turkish, Dutch, Ukrainian, Vietnamese, Indonesian, Japanese, Italian, Korean, Thai, Polish, Romanian, Greek, Czech, Finnish, Hindi, Bulgarian, Danish, Hebrew, Malay, Persian, Slovak, Swedish, Croatian, Filipino, Hungarian, Norwegian, Slovenian, Catalan, Nynorsk, Tamil, Afrikaans, auto"
},
"stream_options": {
"type": "object",
"required": [
"exclude_aggregated_audio"
],
"properties": {
"exclude_aggregated_audio": {
"type": "string",
"description": "设置最后一个 chunk 是否包含拼接后的语音 hex 数据。默认值为 False,即最后一个 chunk 中包含拼接后的完整语音 hex 数据"
}
}
},
"timber_weights": {
"type": "object",
"required": [
"voice_id",
"weight"
],
"properties": {
"weight": {
"type": "integer",
"description": "合成音频各音色所占的权重,须与 voice_id 同步填写。可选值范围为[1, 100],最多支持 4 种音色混合,单一音色取值占比越高,合成音色与该音色相似度越高."
},
" voice_id": {
"type": "string"
}
}
},
"subtitle_enable": {
"type": "boolean"
},
" subtitle_enable": {
"type": "boolean",
"description": "控制是否开启字幕服务,默认值为 false。此参数仅在非流式输出场景下有效,且仅对 speech-2.6-hd speech-2.6-turbo speech-02-turbo speech-02-hd speech-01-turbo speech-01-hd 模型有效"
},
"pronunciation_dict": {
"type": "object",
"properties": {
"tone": {
"type": "array",
"items": {
"type": "string",
"description": "定义需要特殊标注的文字或符号对应的注音或发音替换规则。在中文文本中,声调用数字表示:\n一声为 1,二声为 2,三声为 3,四声为 4,轻声为 5\n示例如下:\n[\"燕少飞/(yan4)(shao3)(fei1)\", \"omg/oh my god\"]"
}
}
}
}
},
"x-apifox-id": "379964423"
}
}
},
"required": true
}
}价格
| 价格组 | 渠道 | 计费项 | 价格 | 单位 |
|---|---|---|---|---|
| default | 本站 AI 中转站 | request | CNY 3.5 | request |
服务级错误码参照(error_code):
| 错误码 | 说明 | |
|---|---|---|
| 221301 | 数据源超时 | |
| 221303 | 认证失败 认证失败,请稍后重试 认证失败,该卡当日连续多次认证不通过被限制校验,次日恢复 |
|
| 221306 | 参数错误 参数错误:姓名格式不正确 参数错误:手机号格式不正确 参数错误:身份证格式不正确 参数错误:银行卡号格式不正确 同一银行卡请求过于频繁 |
系统级错误码参照:
| 错误码 | 说明 | |
|---|---|---|
| 10001 | 错误的请求KEY | |
| 10002 | 该KEY无请求权限 | |
| 10003 | KEY过期 | |
| 10004 | 错误的OPENID | |
| 10005 | 应用未审核超时,请提交认证 | |
| 10007 | 未知的请求源 | |
| 10008 | 被禁止的IP | |
| 10009 | 被禁止的KEY | |
| 10011 | 当前IP请求超过限制 | |
| 10012 | 请求超过次数限制 | |
| 10013 | 测试KEY超过请求限制 | |
| 10014 | 系统内部异常(调用充值类业务时,请务必联系客服或通过订单查询接口检测订单,避免造成损失) | |
| 10020 | 接口维护 | |
| 10021 | 接口停用 |
错误码格式说明(示例:200201):
| 2 | 002 | 01 | |
|---|---|---|---|
| 服务级错误(1为系统级错误) | 服务模块代码(即数据ID) | 具体错误代码 |
使用文档下载
| 附件标题/下载链接 | 更新时间 | |
|---|---|---|
| 接口资料:POST /minimax/v1/t2a_v2(同步语音合成) | 2026-11-02 17:04:55 | |
| 价格分组:default(CNY 3.5/request) | 2026-11-02 17:04:55 | |
| 供应商令牌分组折扣资料 | 2026-11-02 17:04:55 |
常见问题:
| 标题 | 更新时间 | |
|---|---|---|
| Token 是什么?中文、英文与上下文窗口如何计算 | 2026-11-04 14:16:20 | |
| LLM API 费用如何计算?如何选择合适的模型 | 2026-11-04 14:36:14 | |
| Word-to-Token 转换与用量估算指南 | 2026-11-04 12:35:17 |
gemini-4-argon-thinking-medium