Updates a stream mix task.
Operation description
You can call this API operation to update a stream mix task. You can update the input sources and layout, but you cannot update parameters such as the output resolution.
QPS limit
The queries per second (QPS) limit for a single user is 10 calls per second. If you exceed this limit, your API calls are throttled. This may impact your business. Plan your calls accordingly.
Try it now
Test
RAM authorization
Action | Access level | Resource type | Condition key | Dependent action |
live:UpdateMixStream | update | *Domain
| None | None |
Request parameters
Parameter | Type | Required | Description | Example |
RegionId | string | No | The region ID. | cn-shanghai |
DomainName | string | Yes | The streaming domain. Important Only domain names in the China (Shanghai) and China (Beijing) regions are supported. | example.com |
MixStreamId | string | Yes | The ID of the stream mix task. If you created the task by calling the CreateMixStream operation, use the MixStreamId value returned in the response. | 5b2a046e-74d7-385e-d2d7-8a5b87e4**** |
InputStreamList | string | Yes | The list of input streams for the mix. This is a JSON array. For more information, see InputStreamConfig below. | {"InputStreamList":[{"LayoutConfig":{"FillSizeNormalized":[0.5,0.5],"FillPositionNormalized":[0,0],"PositionRefer":"topLeft","FillMode":"fit"},"LayoutChildId":1,"ResourceValue":"rtmp://aliyundoc.com/caster/8564a8d1659b4dc69df5f66cf4c9****","ResourceType":"live"},{"LayoutConfig":{"FillSizeNormalized":[0.5,0.5],"FillPositionNormalized":[0.5,0],"PositionRefer":"topLeft","FillMode":"fit"},"LayoutChildId":2,"ResourceValue":"http://developer.aliyundoc.com/3c3c25426cf744fdb90423e76b78a28a/69b1a16e2b1d423d9841bf27a96f134e-0b1cba51f58bb5ad3a854x96a2c735f****.mp4","ResourceType":"url"},{"LayoutConfig":{"FillSizeNormalized":[1,0.5],"FillPositionNormalized":[0,0.5],"PositionRefer":"topLeft","FillMode":"fit"},"LayoutChildId":3,"ResourceValue":"http://aliyundoc.com/c0c6c5446b56432389e91535864938da/ed4adc5263b4474c954b95607a5350ae-fda757b3328438a8cf-4k57f373a0f0****.mp4","ResourceType":"url"}]} |
LayoutId | string | No | The layout ID. The following values are supported:
| MixStreamLayout-3-2 |
InputStreamConfig
Name | Type | Description |
ResourceType | String | The resource type. |
ResourceValue | String | The resource URL. |
LayoutChildId | String | The ID of the layout pane. This ID also determines the stacking order of the streams. |
LayoutConfig | LayoutConfig[] | A JSON array that specifies layout information, such as the position and fill mode. |
LayoutConfig
Name | Type | Required | Description |
FillSizeNormalized | JSON array of floating-point numbers | Yes | The size of the area to fill for this layer element. |
FillPositionNormalized | Array of floating-point numbers | Yes | The normalized position of the fill area for this layer element. |
PositionRefer | String | No | The reference coordinate for the position of the element. |
FillMode | String | No | The fill mode for the element. |
Response elements
Element | Type | Description | Example |
object | |||
MixStreamId | string | The ID of the stream mix task. You can use this ID to query or delete the task. | 5b2a046e-74d7-385e-d2d7-8a5b87e4**** |
RequestId | string | The request ID. | 1A8CDDFF-0121-4ABB-DA60-AEF095A8W34F |
Examples
Success response
JSON format
{
"MixStreamId": "5b2a046e-74d7-385e-d2d7-8a5b87e4****",
"RequestId": "1A8CDDFF-0121-4ABB-DA60-AEF095A8W34F"
}Error codes
HTTP status code | Error code | Error message | Description |
400 | InvalidUserId.Malformed | %s, please check userId. | The userId passed in is invalid, please check. |
400 | InvalidParameter.Malformed | There are invalid parameters: %s. | There are invalid parameters: %s. |
400 | MissingParameter | %s. | Missing parameter |
401 | IllegalOperation | %s, please check and try again later. | Operation not allowed, please check and try again. |
500 | InternalError | %s, please try again later. | Internal error, please try again later. |
403 | MixStreamAlreadyExist | %s, please check and try again later. | The confluence task already exists, please check and try again. |
403 | MixStreamNotExist | %s, please check and try again later. | The confluous task does not exist. Please check and try again. |
404 | InvalidDomainName.NotFound | %s, please check and try again later. | Domain name does not exist, please check and try again. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.