Starts playback for an episode list.
Usage note
The ProgramId parameter is required in the request.
QPS limit
A single user can perform a maximum of 10 queries per second (QPS). Throttling is triggered when the number of calls per second exceeds the QPS limit. The throttling may affect your business. Thus, we recommend that you observe the QPS limit on this operation. For more information about what a single user means and the QPS details, see QPS limit on an API operation in ApsaraVideo Live.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | StartPlaylist |
The operation that you want to perform. Set the value to StartPlaylist. |
ProgramId | String | Yes | 445409ec-7eaa-461d-8f29-4bec2eb9**** |
The ID of the episode list for which you want to start playback. It is included in the response when you call the AddPlaylistItems operation. |
ResumeMode | String | No | Custom |
The method to resume the playback of the episode list. Valid values:
|
StartItemId | String | No | asdfasdfasdf**** |
The ID of the first episode to play. This episode is the first to play in carousel playback. Note If you set the ResumeMode parameter to Custom, this parameter is required.
|
Offset | Integer | No | 10000 |
The offset of the position where the system starts to play the episode. This parameter is returned only if the episode resource is a file. Unit: milliseconds. A value greater than 0 indicates an offset from the first frame. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
ProgramId | String | 445409ec-7eaa-461d-8f29-4bec2eb9**** |
The ID of the episode list that started to play. |
RequestId | String | 5c6a2a0d-f228-4a64-af62-20e91b96**** |
The ID of the request. |
StreamInfo | Struct |
The information about the stream that is used to play the episode list. |
|
AppName | String | liveApp****r |
The name of the application. |
DomainName | String | example.com |
The main streaming domain. |
StreamName | String | liveStream**** |
The name of the live stream. |
Streams | Array of Stream |
The information about the live stream that was generated for playback based on different protocols. |
|
Stream | |||
PullFlvUrl | String | http://aliyundoc.com/caster/liveStream****.flv?auth_key=1612772224-0-0-3632be7cd9907169e8b09e91099c**** |
The Flash Video (FV) URL of the live stream. |
PullM3U8Url | String | rtmp:///aliyundoc.com/caster/liveStream****?auth_key=1612772224-0-0-4404ca59c0246226d49d01f734b1**** |
The Real-Time Messaging Protocol (RTMP) URL of the live stream. |
PullRtmpUrl | String | http://aliyundoc.com/caster/liveStream****.m3u8?auth_key=1612772224-0-0-919a023a127156fe82e3562c3b3b**** |
The M3U8 URL of the live stream. |
Quality | String | original |
The image quality of the live stream. Valid value: original: original quality |
Examples
Sample requests
http(s)://live.aliyuncs.com/?Action=StartPlaylist
&ProgramId=445409ec-7eaa-461d-8f29-4bec2eb9****
&ResumeMode=Custom
&StartItemId=asdfasdfasdf****
&Offset=10000
&<Common request parameters>
Sample success responses
XML
format
<StartPlaylistResponse>
<RequestId>5c6a2a0d-f228-4a64-af62-20e91b96****</RequestId>
<StreamInfo>
<StreamName>liveStream****</StreamName>
<DomainName>example.com</DomainName>
<AppName>liveApp****</AppName>
<Streams>
<Stream>
<PullFlvUrl>http://aliyundoc.com/caster/liveStream****.flv?auth_key=1612772224-0-0-3632be7cd9907169e8b09e91099c****</PullFlvUrl>
<PullM3U8Url>rtmp:///aliyundoc.com/caster/liveStream****?auth_key=1612772224-0-0-4404ca59c0246226d49d01f734b1****</PullM3U8Url>
<Quality>original</Quality>
<PullRtmpUrl>http://aliyundoc.com/caster/liveStream****.m3u8?auth_key=1612772224-0-0-919a023a127156fe82e3562c3b3b****</PullRtmpUrl>
</Stream>
</Streams>
</StreamInfo>
<ProgramId>445409ec-7eaa-461d-8f29-4bec2eb9****</ProgramId>
</StartPlaylistResponse>
JSON
format
{
"StartPlaylistResponse": {
"RequestId": "5c6a2a0d-f228-4a64-af62-20e91b96****",
"StreamInfo": {
"StreamName": "liveStream****",
"DomainName": "example.com",
"AppName": "liveApp****",
"Streams": {
"Stream": {
"PullFlvUrl": "http://aliyundoc.com/caster/liveStream****.flv?auth_key=1612772224-0-0-3632be7cd9907169e8b09e91099c****",
"PullM3U8Url": "rtmp:///aliyundoc.com/caster/liveStream****?auth_key=1612772224-0-0-4404ca59c0246226d49d01f734b1****",
"Quality": "original",
"PullRtmpUrl": "http://aliyundoc.com/caster/liveStream****.m3u8?auth_key=1612772224-0-0-919a023a127156fe82e3562c3b3b****"
}
}
},
"ProgramId": "445409ec-7eaa-461d-8f29-4bec2eb9****"
}
}
Error codes
For a list of error codes, visit the API Error Center.