Adds an episode to a production studio.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes AddCasterEpisode

The operation that you want to perform. Set the value to AddCasterEpisode.

CasterId String Yes LIVEPRODUCER_POST-cn-0pp1czt****

The ID of the production studio.

EndTime String Yes 2016-06-29T09:10:00Z

The time when the episode ends. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

EpisodeType String Yes Resource

The type of the episode. Valid values:

  • Resource: a video resource.
  • Component: a component.
StartTime String Yes 2016-06-29T08:00:00Z

The time when the episode starts. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

SwitchType String Yes TimeFirst

The policy for switching episodes. Valid values:

  • TimeFirst: The episode starts when the preceding episode ends and ends when the next episode starts. If no next episode exists, the episode keeps repeating until a new episode is added or the production studio stops.
  • ContentFirst: The episode starts and ends as scheduled.

This parameter takes effect only when the EpisodeType parameter is set to Resource.

Note This parameter must be set to TimeFirst when the video resource is a live stream.
RegionId String No cn-shanghai

The ID of the region.

EpisodeName String No episode_1

The name of the episode.

ResourceId String No a2b8e671-2fe5-4642-a2ec-bf93880e****

The ID of the video resource.

This parameter takes effect and is required only when the EpisodeType parameter is set to Resource.

ComponentId.N RepeatList No ["a2b8e671-2fe5-4642-a2ec-bf93880e****"]

The ID of the component. Components in the production studio are listed from the bottom to the top in an array.

  • This parameter takes effect and is required when the EpisodeType parameter is set to Component.
  • This parameter is optional when the EpisodeType parameter is set to Resource. In this case, if this parameter is specified, the components are bound with and switched together with video resources.
Note The variable N indicates the sequence number of the component. For example, the ComponentId.1 parameter specifies the ID of the first component. The ComponentId.2 parameter specifies the ID of the second component.

Response parameters

Parameter Type Example Description
EpisodeId String 21926b36-7dd2-4fde-ae25-51b5bc8e****

The ID of the episode that was added.

RequestId String 16A96B9A-F203-4EC5-8E43-CB92E68F4CD8

The ID of the request.

Examples

Sample requests

http(s)://live.aliyuncs.com/? Action=AddCasterEpisode
&CasterId=LIVEPRODUCER_POST-cn-0pp1czt****
&EndTime=2016-06-29T09:10:00Z
&EpisodeType=Resource
&StartTime=2016-06-29T08:00:00Z
&SwitchType=TimeFirst
&<Common request parameters>

Sample success responses

XML format

<AddCasterEpisodeResponse>
	  <RequestId>16A96B9A-F203-4EC5-8E43-CB92E68F4CD8</RequestId>
	  <EpisodeId>21926b36-7dd2-4fde-ae25-51b5bc8e****</EpisodeId>
</AddCasterEpisodeResponse>

JSON format

{
    "RequestId": "16A96B9A-F203-4EC5-8E43-CB92E68F4CD8",
    "EpisodeId": "21926b36-7dd2-4fde-ae25-51b5bc8e52d8"
}

Error codes

For a list of error codes, visit the API Error Center.