功能描述
UpdateMediaQueue 接口用于更新队列。
请求
请求示例
PUT /queue/p8eb46b8cc1a94bc09512d16c5c4f4d3a HTTP/1.1Host: <BucketName-APPID>.ci.<Region>.myqcloud.comDate: <GMT Date>Authorization: <Auth String>Content-Length: <length>Content-Type: application/xml<body>
说明
请求头
请求体
该请求操作的实现需要有以下请求体。
<Request><Name>Queue Name</Name><QueueID></QueueID><State></State><NotifyConfig><Type></Type><Url></Url><Event></Event></NotifyConfig></Request>
具体数据描述如下:
节点名称(关键字) | 父节点 | 描述 | 类型 | 是否必选 |
Request | 无 | 保存请求的容器 | Container | 是 |
Container 类型 Request 的具体数据描述如下:
节点名称(关键字) | 父节点 | 描述 | 类型 | 是否必选 | 限制 |
Name | Request | 模板名称 | String | 是 | 长度限制100字符 |
QueueID | Request | 管道 ID | String | 是 | - |
State | Request | 管道状态 | String | 是 | 1. Active 表示管道内的作业会被媒体转码服务调度转码执行 2. Paused 表示管道暂停,作业不再会被媒体转码调度转码执行,管道内的所有作业状态维持在已提交状态,已经处于转码中的任务将继续转码,不受影响 |
NotifyConfig | Request | 通知渠道 | Container | 是 | 第三方回调 Url |
Container 类型 NotifyConfig 的具体数据描述如下:
节点名称(关键字) | 父节点 | 描述 | 类型 | 是否必选 | 限制 |
Url | Request.NotifyConfig | 回调配置 | String | 否 | 长度限制100字符 |
Type | Request.NotifyConfig | 回调类型,普通回调:Url | String | 否 | 长度限制100字符 |
Event | Request.NotifyConfig | 任务完成:TaskFinish;工作流完成:WorkflowFinishh | String | 否 | 长度限制100字符 |
State | Request.NotifyConfig | 回调开关,Off,On | String | 否 | 长度限制100字符 |
响应
响应头
响应体
该响应体返回为 application/xml 数据,包含完整节点数据的内容展示如下:
<Response><RequestId>NTk0MjdmODlfMjQ4OGY3XzYzYzhf****</RequestId><Queue><QueueId></QueueId><Name></Name><State>Active</State><NotifyConfig><Url>mts-topic-1</Url><Type></Type><Event></Event></NotifyConfig><CreateTime></CreateTime><UpdateTime></UpdateTime></Queue></Response>
具体的数据内容如下:
节点名称(关键字) | 父节点 | 描述 | 类型 |
Response | 无 | 保存结果的容器 | Container |
Container 节点 Response 的内容:
节点名称(关键字) | 父节点 | 描述 | 类型 |
RequestId | Response | 请求的唯一 ID | String |
Queue | Response | Container |
错误码
实际案例
请求
PUT /queue/p8eb46b8cc1a94bc09512d16c5c4f4d3a HTTP/1.1Authorization: q-sign-algorithm=sha1&q-ak=AKIDZfbOAo7cllgPvF9cXFrJD0a1ICvR****&q-sign-time=1497530202;1497610202&q-key-time=1497530202;1497610202&q-header-list=&q-url-param-list=&q-signature=28e9a4986df11bed0255e97ff90500557e0e****Host: examplebucket-1250000000.ci.ap-beijing.myqcloud.comContent-Length: 1666Content-Type: application/xml<Request><Name>Queue Name</Name><QueueID></QueueID><State></State><NotifyConfig><Type></Type><Url></Url><Event></Event></NotifyConfig></Request>
响应
HTTP/1.1 200 OKContent-Type: application/xmlContent-Length: 100Connection: keep-aliveDate: Thu, 15 Jun 2017 12:37:29 GMTServer: tencent-cix-ci-request-id: NTk0MjdmODlfMjQ4OGY3XzYzYzhf****<Response><RequestId>NTk0MjdmODlfMjQ4OGY3XzYzYzhf****</RequestId><Queue><QueueID></QueueID><Name></Name><State>Active</State><NotifyConfig><Type></Type><Url></Url><Event></Event></NotifyConfig><CreateTime></CreateTime><UpdateTime></UpdateTime></Queue></Response>