DescribeMediaTemplates 用于搜索语音合成转码模板。
GET /template HTTP/1.1
Host: <BucketName-APPID>.ci.<Region>.myqcloud.com
Date: <GMT Date>
Authorization: <Auth String>
Content-Length: <length>
Content-Type: application/xml
说明:Authorization: Auth String (详情请参见 请求签名 文档)。
此接口仅使用公共请求头部,详情请参见 公共请求头部 文档。
该请求的请求体为空。
参数的具体内容如下:
节点名称(关键字) | 父节点 | 描述 | 类型 | 是否必选 |
---|---|---|---|---|
Tag | 无 | 模板Tag:Tts | String | 是 |
Category | 无 | 枚举值:Official、Custom,默认值:Custom | String | 是 |
Ids | 无 | 模板 ID,以, 符号分割字符串 |
String | 否 |
Name | 无 | 模板名称前缀 | String | 否 |
PageNumber | 无 | 第几页 | Integer | 否 |
PageSize | 无 | 每页个数 | Integer | 否 |
此接口仅返回公共响应头部,详情请参见 公共响应头部 文档。
该响应体返回为 application/xml 数据,包含完整节点数据的内容展示如下:
<Response>
<RequestId>NTk0MjdmODlfMjQ4OGY3XzYzYzhfMjc=</RequestId>
<TotalCount>1</TotalCount>
<PageNumber>1</PageNumber>
<PageSize>10</PageSize>
<TemplateList>
<TemplateId>A</TemplateId>
<Name>TemplateName</Name>
<Tag>Tts</Tag>
<TtsTpl>
<Mode>Sync</Mode>
<Codec>pcm</Codec>
<VoiceType>ruxue</VoiceType>
<Volume>2</Volume>
<Speed>200</Speed>
</TtsTpl>
<CreateTime>2020-08-05T11:35:24+0800</CreateTime>
<UpdateTime>2020-08-31T16:15:20+0800</UpdateTime>
</TemplateList>
</Response>
具体的数据内容如下:
节点名称(关键字) | 父节点 | 描述 | 类型 |
---|---|---|---|
Response | 无 | 保存结果的容器 | Container |
Container 节点 Response 的内容:
节点名称(关键字) | 父节点 | 描述 | 类型 |
---|---|---|---|
RequestId | Response | 请求的唯一 ID | String |
TotalCount | Response | 模板总数 | Int |
PageNumber | Response | 当前页数,同请求中的 pageNumber | Int |
PageSize | Response | 每页个数,同请求中的 pageSize | Int |
TemplateList | Response | 模板数组 | Container |
Container节点TemplateList的内容:
节点名称(关键字) | 父节点 | 描述 | 类型 |
---|---|---|---|
TemplateId | Response.TemplateList | 模板 ID | String |
Name | Response.TemplateList | 模板名称 | String |
BucketId | Response.TemplateList | 模板所属存储桶 | String |
Category | Response.TemplateList | 模板属性,Custom 或者 Official | String |
Tag | Response.TemplateList | 模板类型,Tts | String |
UpdateTime | Response.TemplateList | 更新时间 | String |
CreateTime | Response.TemplateList | 创建时间 | String |
Tts | Response.TemplateList | 详细的模板参数 | Container |
该请求操作无特殊错误信息,常见的错误信息请参见 错误码 文档。
GET /template?ids=A,B,C HTTP/1.1
Authorization:q-sign-algorithm=sha1&q-ak=AKIDZfbOAo7cllgPvF9cXFrJD0**********&q-sign-time=1497530202;1497610202&q-key-time=1497530202;1497610202&q-header-list=&q-url-param-list=&q-signature=28e9a4986df11bed0255e97ff90500557e0ea057
Host:bucket-1250000000.ci.ap-beijing.myqcloud.com
Content-Length: 0
Content-Type: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: 100
Connection: keep-alive
Date: Thu, 15 Jun 2017 12:37:29 GMT
Server: tencent-ci
x-ci-request-id: NTk0MjdmODlfMjQ4OGY3XzYzYzhf****
<Response>
<RequestId>NTk0MjdmODlfMjQ4OGY3XzYzYzhf****</RequestId>
<TemplateList>
<TemplateId>A</TemplateId>
<Name>TemplateName</Name>
<Tag>Tts</Tag>
<TtsTpl>
<Mode>Sync</Mode>
<Codec>pcm</Codec>
<VoiceType>ruxue</VoiceType>
<Volume>2</Volume>
<Speed>200</Speed>
</TtsTpl>
<CreateTime>2020-08-05T11:35:24+0800</CreateTime>
<UpdateTime>2020-08-31T16:15:20+0800</UpdateTime>
</TemplateList>
<NonExistTIDs>
<TemplateId>B</TemplateId>
<TemplateId>C</TemplateId>
</NonExistTIDs>
</Response>
GET /template?pageSize=10&pageNumber=1 HTTP/1.1
Authorization: q-sign-algorithm=sha1&q-ak=AKIDZfbOAo7cllgPvF9cXFrJD0**********&q-sign-time=1497530202;1497610202&q-key-time=1497530202;1497610202&q-header-list=&q-url-param-list=&q-signature=28e9a4986df11bed0255e97ff90500557e0ea057
Host: examplebucket-1250000000.ci.ap-beijing.myqcloud.com
Content-Length: 0
Content-Type: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: 100
Connection: keep-alive
Date: Thu, 15 Jun 2017 12:37:29 GMT
Server: tencent-ci
x-ci-request-id: NTk0MjdmODlfMjQ4OGY3XzYzYzhf****
<Response>
<RequestId>NTk0MjdmODlfMjQ4OGY3XzYzYzhfMjc=</RequestId>
<TotalCount>1</TotalCount>
<PageNumber>1</PageNumber>
<PageSize>10</PageSize>
<TemplateList>
<TemplateId>A</TemplateId>
<Name>TemplateName</Name>
<Tag>Tts</Tag>
<TtsTpl>
<Mode>Sync</Mode>
<Codec>pcm</Codec>
<VoiceType>ruxue</VoiceType>
<Volume>2</Volume>
<Speed>200</Speed>
</TtsTpl>
<CreateTime>2020-08-05T11:35:24+0800</CreateTime>
<UpdateTime>2020-08-31T16:15:20+0800</UpdateTime>
</TemplateList>
</Response>
本页内容是否解决了您的问题?