Sets all parameters for a production studio. If a parameter is not specified, the production studio does not have the relevant configuration.

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 SetCasterConfig

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

CasterId String Yes a2b8e671-2fe5-4642-a2ec-bf93880e****

The ID of the production studio.

RegionId String No cn-shanghai

The ID of the region.

CasterName String No caster001

The name of the production studio.

DomainName String No test.live.com

The main streaming domain.

Configure the domain name before the product studio is started. If you do not set this parameter, the domain configuration for the production studio is cleared.

TranscodeConfig String No {"casterTemplate": "lp_ld"}

The configuration about transcoding for the production studio.

Set the value to a JSON string. Use upper camel case for fields of the string. If you do not set this parameter, the transcoding configuration of the production studio is cleared.

RecordConfig String No { "endpoint": "http://service.cn-hangzhou.live.aliyun.com/api", "ossBucket": "test123", "videoFormat": ["flv","m3u8" ] "interval": 5 }

The configuration about recording for the production studio, in the JSON format. You can configure the following elements:

  • endpoint: the address of the API server of an Alibaba Cloud service.
  • ossBucket: the name of the Object Storage Service (OSS) bucket.
  • videoFormat: the format in which the video file can be exported. Example: ["flv","m3u8" ].
  • interval: the interval at which a recording starts. Unit: milliseconds.
Note If you do not set this parameter, the recording feature is disabled. If a field in the parameter is not specified, the corresponding configuration is cleared for the production studio.
Delay Float No 0

Specifies whether to enable stream delay. Unit: seconds. Valid values:

  • 0: disables stream delay. This is the default value.
  • A value greater than 0: the delay duration.
  • Empty: clears the stream delay configuration.
UrgentMaterialId String No a2b8e671

The ID of the material that is used as the standby video from the media library. If this parameter is not specified, the standby playback configuration of the production studio is cleared.

SideOutputUrl String No http://side/aliyunlive:8000/caster/4a82a3d1b7f0462ea37348366201****?auth_key=1608953344-0-0-53f0758162964516ac850f2ddc3f****

The custom standby URL. If this parameter is not specified, the production studio uses the ingest URL generated by the system.

CallbackUrl String No http://sophon/aliyunlive:8000/caster/4a82a3d1b7f0462ea37348366201****?auth_key=1608953344-0-0-53f0758162964516ac850f2ddc3f****

The callback URL. Enter a valid HTTP address for receiving callback notifications. If this parameter is not specified, the production studio does not send callback notifications.

ProgramEffect Integer No 1

Specifies whether the carousel playback is enabled. Valid values:

  • 0: disables the carousel playback.
  • 1: enables the carousel playback.
ProgramName String No program_name

The name of the carousel list. You can set this parameter when you enable the carousel playback.

ChannelEnable Integer No 1

Specifies whether channels are enabled for the production studio.

  • 0: disables channels. This is the default value.
  • 1: enables channels.
Note The default value is 0. You cannot disable channels after you enable them. If you set this parameter to 0, the production studio references video resources in a layout without using channels. When you enable channels for the first time, make sure that the production studio is in the idle state. In this case, a new layout is generated to replace the original one. The new layout references video resources by using channels. Therefore, you must specify video resources for the channels. You can use channels to change the playback progress or status. If you enable channels and the video resource, preview, and program modules of the production studio use the same video source, the three sections display the same images.

Response parameters

Parameter Type Example Description
CasterId String b4810848-bcf9-4aef-bd4a-e6bba2d9****

The ID of the production studio.

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

The ID of the request.

Examples

Sample requests

http(s)://live.aliyuncs.com/? Action=SetCasterConfig
&CasterId=a2b8e671-2fe5-4642-a2ec-bf93880e****
&<Common request parameters>

Sample success responses

XML format

<SetCasterConfigResponse>
      <RequestId>16A96B9A-F203-4EC5-8E43-CB92E68F4CD8</RequestId>
      <casterId>b4810848-bcf9-4aef-bd4a-e6bba2d9****</casterId>
</SetCasterConfigResponse>

JSON format

{
    "RequestId": "16A96B9A-F203-4EC5-8E43-CB92E68F4CD8",
    "casterId": "b4810848-bcf9-4aef-bd4a-e6bba2d9****"
}

Error codes

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