All Products
Search
Document Center

Intelligent Media Services:GetLiveRecordTemplate

Last Updated:Dec 16, 2024

Queries the information about a live stream recording template or a snapshot of the template.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
ice:GetLiveRecordTemplate
*All Resources
*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
TemplateIdstringYes

The template ID.

69e1f9fe-1e97-11ed-ba64-0c42a1b73d66
JobIdstringNo

The ID of the recording job. You can specify the JobId parameter to retrieve the snapshot of the template used by the job.

ab0e3e76-1e9d-11ed-ba64-0c42a1b73d66

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

RecordTemplateobject

The recording template.

RecordFormatListarray<object>

The list of recording formats.

recordFormatobject

The recording format.

Formatstring

The output file format.

m3u8
OssObjectPrefixstring

The name of the recording file that is stored in Object Storage Service (OSS).

record/{JobId}/{Sequence}{EscapedStartTime}{EscapedEndTime}
SliceOssObjectPrefixstring

The name of the TS segment.

record/{JobId}/{UnixTimestamp}_{Sequence}
CycleDurationinteger

The duration of the recording cycle. Unit: seconds. If you do not specify this parameter, the default value 6 hours is used.

7200
SliceDurationinteger

The duration of a single segment. Unit: seconds.

30
CreateTimestring

The time when the job was created.

2022-07-20T03:26:36Z
LastModifiedstring

The time when the template was last modified.

2022-07-20T03:26:36Z
TemplateIdstring

The template ID.

69e1f9fe-1e97-11ed-ba64-0c42a1b73d66
Namestring

The template name.

test template
Typestring

The type of the template.

Valid values:

  • system
  • custom
custom
RequestIdstring

The request ID.

C892855F-95DF-50D6-A28C-279ABDB76810

Examples

Sample success responses

JSONformat

{
  "RecordTemplate": {
    "RecordFormatList": [
      {
        "Format": "m3u8",
        "OssObjectPrefix": "record/{JobId}/{Sequence}{EscapedStartTime}{EscapedEndTime}",
        "SliceOssObjectPrefix": "record/{JobId}/{UnixTimestamp}_{Sequence}",
        "CycleDuration": 7200,
        "SliceDuration": 30
      }
    ],
    "CreateTime": "2022-07-20T03:26:36Z",
    "LastModified": "2022-07-20T03:26:36Z",
    "TemplateId": "69e1f9fe-1e97-11ed-ba64-0c42a1b73d66",
    "Name": "test template",
    "Type": "custom"
  },
  "RequestId": "C892855F-95DF-50D6-A28C-279ABDB76810"
}

Error codes

For a list of error codes, visit the Service error codes.