语音合成 语音合成
接口介绍

语音合成价格:1点/20字(标点符号不计算在内)

接口计费 VIP特权
1,000 点数 / ¥99.90
10,000 点数 / ¥999.00
100,000 点数 / ¥9989.00
暂无VIP特权
接口文档

1. 接口基础

使用前请阅读 接口基础

2. 任务提交(异步)

请求地址

[POST] https://api.tecmz.com/open_api/cloud_sound_tts/queue

请求参数

参数 必须 类型 说明
speaker 声音 名称
text string 需要合成的文字

返回

{
    "code": 0,
    "msg": "ok",
    "data": {
        // 任务ID
        "taskId": "1"
    }
}

3. 任务查询

建议 10 秒查询一次转换结果。

请求地址

[POST] https://api.tecmz.com/open_api/cloud_sound_tts/query

请求参数

参数 必须 类型 错误说明
taskId integer 任务ID

返回

{
    "code": 0,
    "msg": "ok",
    "data": {
        // 任务ID
        "taskId": "1",
        // QUEUE 队列中 PROCESS 处理中 FAIL 转换失败 SUCCESS 转换成功
        "status": "QUEUE",
        // 结果
        "result": {
            // 音频链接
            "url": "http://example.com/result.wav"
        }
    }
}
展开
QQ
微信
公众号
客服