AddCasterProgram
Adds an episode list to a production studio.
Operation description
Before you call this operation to add an episode list to a production studio, create a production studio and add video resources to the production studio. This operation supports only video sources and components as node types. To create a production studio by calling an API operation, see Create a production studio.
QPS limits
The QPS limit for a single user is 10 calls per second. If the limit is exceeded, API calls are throttled, which may affect your business. Call this operation at a reasonable frequency.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
live:AddCasterProgram |
create |
*Caster
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
No |
The region ID. |
cn-shanghai |
| Episode |
array<object> |
Yes |
The episode list information. |
|
|
object |
No |
The episode list information. |
||
| ComponentId |
array |
No |
The list of components. The elements are arranged from bottom to top based on their order in the list. Important This parameter is valid and required when Episode.N.EpisodeType is set to Component.
When the node type is Resource, this parameter indicates that the component is bound to the video source and switches synchronously. |
[ "a2b8e671-2fe5-4642-a2ec-bf931826****", "a2b8e671-2fe5-4642-a2ec-28374657****"] |
|
string |
No |
The component ID. |
a2b8e671-2fe5-4642-a2ec-bf931826**** |
|
| EndTime |
string |
No |
The end time. Specify the time in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. This parameter is required. If you do not specify this parameter, the MissingParameter error is returned. |
2016-06-29T10:02:00Z |
| EpisodeName |
string |
No |
The episode name. |
program_name_1 |
| EpisodeType |
string |
No |
The node type. Valid values:
Note
|
Resource |
| ResourceId |
string |
No |
The video source ID. Important This parameter is valid and required when Episode.N.EpisodeType is set to Resource.
This parameter is invalid when Episode.N.EpisodeType is set to Component. If you added a video source to the production studio by calling the AddCasterVideoResource operation, you can view the value of the ResourceId parameter returned by the AddCasterVideoResource operation. |
a2b8e671-2fe5-4642-a2ec-bf93880e**** |
| StartTime |
string |
No |
The start time. Specify the time in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. This parameter is required. If you do not specify this parameter, the MissingParameter error is returned. |
2016-06-29T09:00:00Z |
| SwitchType |
string |
No |
The switching policy. Valid values: Important This parameter is valid only when Episode.N.EpisodeType is set to Resource.
|
TimeFirst |
| CasterId |
string |
Yes |
The production studio ID.
Note
The production studio name in the production studio list on the Cloud Production Studios page of the ApsaraVideo Live console is the production studio ID. |
LIVEPRODUCER_POST-cn-0pp1czt**** |
The N in the request parameter indicates the sequence number. For example,
Episode.N.EpisodeName indicates the name of the Nth episode. Episode.1.EpisodeName indicates the name of the first episode, and Episode.2.EpisodeName indicates the name of the second episode.
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| EpisodeIds |
object |
||
| EpisodeId |
array<object> |
The list of episode IDs. The order of the elements in the list is consistent with the order of the episodes passed in the request. |
|
|
object |
|||
| EpisodeId |
string |
The episode ID. You can use this ID as a request parameter to modify the episode list of the production studio, query the episode list of the production studio, delete an episode from the production studio, or modify an episode in the production studio. Note
|
16A96B9A-F203-4EC5-8E43-CB92E68F**** |
| RequestId |
string |
The request ID. |
16A96B9A-F203-4EC5-8E43-CB92E68F**** |
Examples
Success response
JSON format
{
"EpisodeIds": {
"EpisodeId": [
{
"EpisodeId": "16A96B9A-F203-4EC5-8E43-CB92E68F****"
}
]
},
"RequestId": "16A96B9A-F203-4EC5-8E43-CB92E68F****"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | MissingParameter | %s. | Missing parameter |
| 400 | InvalidParameter.Malformed | There are invalid parameters: %s. | There are invalid parameters: %s. |
| 400 | SwitchTypeInvalid.Malformed | %s, please check and try again later. | The parameter SwitchType is invalid, please check and try again. |
| 400 | IncorrectStartTime | %s, please check and try again later. | The parameter StartTime is invalid, please check and try again. |
| 400 | IncorrectEndTime | %s, please check and try again later. | The parameter EndTime is invalid, please check and try again. |
| 400 | EpisodeConflict.Malformed | %s, please check and try again later. | There is a conflict with the program time, please check and try again. |
| 400 | InvalidCasterId.Malformed | %s, please check and try again later. | The parameter CasterId is invalid, please check and try again. |
| 400 | InvalidParameter.EndTime | %s, please check and try again later. | The parameter EndTime is invalid, please check and try again. |
| 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. |
| 404 | InvalidCaster.NotFound | %s, please check and try again later. | The guide station does not exist, please check and try again. |
| 404 | InvalidResource.NotFound | %s, please check and try again later. | The resource does not exist. Please check and try again. |
| 404 | InvalidComponent.NotFound | %s, please check and try again later. | The component to be operated does not exist. Please check and try again. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.