调用GetAllCustomTemplates获取全量自定义合流模板。

使用说明

通过调用本接口获取全量自定义合流模板。返回模板名和模板配置列表。

QPS限制

本接口的单用户QPS限制为10次/秒。超过限制,API调用会被限流,这可能会影响您的业务,请合理调用。更多信息,请参见QPS限制

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

请求参数

名称 类型 是否必选 示例值 描述
Action String GetAllCustomTemplates

系统规定参数。取值:GetAllCustomTemplates

RegionId String cn-shanghai

地域ID。

UserId String 25346073170691****

用户ID。

返回数据

名称 类型 示例值 描述
CustomTemplates String [{"templateConfig": "{\"cdesc\":\"H264\",\"scale\":\"[3:4]\",\"gop\":\"1\",\"bframes\":\"1\",\"height\":\"1080\"}","templateName": "custom1"},{"templateConfig": "{\"ar\":\"44100\",\"cdesc\":\"H264\",\"scale\":\"[3:4]\",\"gop\":\"1\",\"bframes\":\"1\",\"height\":\"1080\"}","templateName": "cus"}]

模板名和模板配置列表。

RequestId String 4791648Q-813C-6254-865C-0ED913661230

请求ID。

示例

请求示例

http(s)://live.aliyuncs.com/?Action=GetAllCustomTemplates
&<公共请求参数>

正常返回示例

XML格式

<GetAllCustomTemplatesResponse>
  <RequestId>4791648Q-813C-6254-865C-0ED913661230</RequestId>
  <CustomTemplates> [{"templateConfig": "{\"cdesc\":\"H264\",\"scale\":\"[3:4]\",\"gop\":\"1\",\"bframes\":\"1\",\"height\":\"1080\"}","templateName": "custom1"},{"templateConfig": "{\"ar\":\"44100\",\"cdesc\":\"H264\",\"scale\":\"[3:4]\",\"gop\":\"1\",\"bframes\":\"1\",\"height\":\"1080\"}","templateName": "cus"}]</CustomTemplates>
</GetAllCustomTemplatesResponse>

JSON格式

{
    "GetAllCustomTemplatesResponse": {
        "RequestId": "4791648Q-813C-6254-865C-0ED913661230",
        "CustomTemplates": "[{\"templateConfig\": \"{\\\"cdesc\\\":\\\"H264\\\",\\\"scale\\\":\\\"[3:4]\\\",\\\"gop\\\":\\\"1\\\",\\\"bframes\\\":\\\"1\\\",\\\"height\\\":\\\"1080\\\"}\",\"templateName\": \"custom1\"},{\"templateConfig\": \"{\\\"ar\\\":\\\"44100\\\",\\\"cdesc\\\":\\\"H264\\\",\\\"scale\\\":\\\"[3:4]\\\",\\\"gop\\\":\\\"1\\\",\\\"bframes\\\":\\\"1\\\",\\\"height\\\":\\\"1080\\\"}\",\"templateName\": \"cus\"}]"
    }
}

错误码

访问错误中心查看更多错误码。