Adds a primary and backup stream merging configuration.
Operation description
The QPS limit for a single user is 100 calls per second. If the limit is exceeded, API calls are throttled, which may affect your business. Make API calls at a reasonable frequency.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
live:AddLiveStreamMerge |
create |
*Domain
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
No |
The region ID. |
cn-shanghai |
| DomainName |
string |
Yes |
The streaming domain. |
example.com |
| AppName |
string |
Yes |
The application name for the merged stream output. The application name must match the application name in the ingest URL for the template to take effect. An asterisk (*) is not allowed. |
app |
| StreamName |
string |
Yes |
The stream name for the merged stream output. The stream name must match the stream name in the ingest URL for the template to take effect. An asterisk (*) is not allowed. |
StreamName |
| InAppName1 |
string |
Yes |
The application name of the primary input stream for merging. The specified application name must match the application name in the ingest URL of the primary stream to take effect. |
app1 |
| InStreamName1 |
string |
Yes |
The stream name of the primary input stream for merging. The specified stream name must match the stream name in the ingest URL of the primary stream to take effect. |
InStream1 |
| InAppName2 |
string |
Yes |
The application name of the backup input stream for merging. The specified application name must match the application name in the ingest URL of the backup stream to take effect. |
app2 |
| InStreamName2 |
string |
Yes |
The stream name of the backup input stream for merging. The specified stream name must match the stream name in the ingest URL of the backup stream to take effect. |
stream2 |
| StartTime |
string |
Yes |
The start time of stream merging. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. |
2020-05-29T00:00:00Z |
| EndTime |
string |
Yes |
The end time of stream merging. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. Note
The maximum time difference between the start time and the end time is 7 days. |
2020-05-29T01:00:00Z |
| Protocol |
string |
No |
The live stream protocol. Valid values:
|
rtmp |
| LiveMerger |
string |
No |
Specifies whether to use the liveswitch engine. Valid values:
|
off |
| MergeParameters |
string |
No |
The configuration parameters for stream switching.
|
ali_low_frame_rate_threshold=10&ali_max_no_frame_timeout=5&block_all_jitter=0 |
| SelectAppName |
string |
No |
||
| SelectStreamName |
string |
No |
||
| SwitchMode |
string |
No |
The switching mode for primary and backup stream merging. Valid values: manually and automatically. |
manually |
The values of AppName, InAppName1, and InAppName2 must be unique. The values of StreamName, InStreamName1, and InStreamName2 must be unique.
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
16A96B9A-F203-4EC5-8E43-CB92E68F**** |
| Message |
string |
|
OK |
The value config invalid, degrade to no livemerger indicates that the configuration of the new liveswitch engine is incomplete, and the system automatically degrades to the legacy engine.
Examples
Success response
JSON format
{
"RequestId": "16A96B9A-F203-4EC5-8E43-CB92E68F****",
"Message": "OK"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidStartTime.Malformed | Specified parameter StartTime is not valid. | |
| 400 | InvalidEndTime.Malformed | Specified parameter EndTime is not valid. | |
| 400 | InvalidStartTime.ValueNotSupported | The specified value of parameter StartTime is not supported. | The value specified for the StartTime parameter is invalid. |
| 400 | InvalidParam | Parameter invalid. | Illegal input parameters |
| 400 | QuotaExceeded.Merge | Exceed max merge count limit | |
| 400 | ConfigAlreadyExists | Config has already exist. | |
| 400 | Duration.Exceed | Duration between StartTime and EndTime is too long. | |
| 400 | InvalidParam.CodeIllegalDuration | %s. | The value of start time should be less than the value of end time . |
| 500 | InternalError | The request processing has failed due to backend service exception. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.