Submits a media file in synchronous mode for media information analysis.
Operation description
You can call this operation to analyze an input media file in synchronous mode. This operation is suitable for scenarios that require high real-time performance and low concurrency. If it takes an extended period of time to obtain the media information about the input media file, the request may time out or the obtained information may be inaccurate. We recommend that you call the SubmitMediaInfoJob operation to obtain media information.
Debugging
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.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
ice:SubmitSyncMediaInfoJob | create | *All Resources * |
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
Name | string | No | The job name. | job-name |
Input | object | Yes | The input of the job. | |
Type | string | Yes | The type of the media object.
| OSS |
Media | string | Yes | The media object.
Note
Before you use the OSS bucket in the URL, you must add the bucket on the Storage Management page of the Intelligent Media Services (IMS) console.
| oss://bucket/path/to/video.mp4 |
UserData | string | No | The user data. | user-data |
ScheduleConfig | object | No | The scheduling parameters. This parameter is optional. | |
PipelineId | string | No | The ID of the MPS queue to which the job was submitted. | e37ebee5d98b4781897f6086e89f9c56 |
Priority | integer | No | The priority of the job. Valid values: 1 to 10. The greater the value, the higher the priority. | 5 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "31E30781-9495-5E2D-A84D-759B0A01E262",
"MediaInfoJob": {
"Name": "job-name",
"TriggerSource": "API",
"JobId": "ab4802364a2e49208c99efab82dfa8e8",
"Input": {
"Type": "OSS",
"Media": "oss://bucket/path/to/video.mp4"
},
"Async": true,
"UserData": "user-data",
"ScheduleConfig": {
"PipelineId": "e37ebee5d98b4781897f6086e89f9c56",
"Priority": 5
},
"Status": "Init",
"SubmitResultJson": {},
"MediaInfoProperty": {
"FileBasicInfo": {
"MediaId": "999e68259c924f52a6be603cbb3f91cc",
"FileName": "file.m3u8",
"FileStatus": "Normal",
"FileType": "source_file",
"FileSize": "31737",
"FileUrl": "http://bucket.oss-cn-shanghai.aliyuncs.com/path/to/file.m3u8",
"Region": "cn-shanghai",
"FormatName": "hls,applehttp",
"Duration": "403.039999",
"Bitrate": "888.563",
"Width": "848",
"Height": "478"
},
"AudioStreamInfoList": [
{
"Index": "1",
"CodecName": "aac",
"CodecLongName": "AAC (Advanced Audio Coding)",
"CodecTimeBase": "1/44100",
"CodecTagString": "[15][0][0][0]",
"CodecTag": "0x000f",
"SampleFmt": "fltp",
"SampleRate": "44100",
"Channels": "2",
"ChannelLayout": "stereo",
"Timebase": "1/90000",
"StartTime": "1.473556",
"Duration": "403.039989",
"Bitrate": "0.f",
"Lang": "us"
}
],
"VideoStreamInfoList": [
{
"Index": "0",
"Codec_name": "h264",
"Codec_long_name": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10",
"Profile": "High",
"Codec_time_base": "1/50",
"Codec_tag_string": "[27][0][0][0]",
"Codec_tag": "0x001b",
"Width": "848",
"Height": "478",
"Has_b_frames": "2",
"Sar": "478:477",
"Dar": "16:9",
"PixFmt": "yuv420p",
"Level": "31",
"Fps": "25.0",
"Avg_fps": "25.0",
"Time_base": "1/90000",
"Start_time": "1.473556",
"Duration": "403.039989",
"Bit_rate": "888.563",
"NumFrames": "10040",
"Lang": "zh",
"Rotate": "0"
}
]
},
"SubmitTime": "2022-01-12T08:49:41Z",
"FinishTime": "2022-01-12T08:49:41Z",
"RequestId": "4879B9DE-E4B6-19DC-91F5-9D5F4DCE4168"
}
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-08-27 | The internal configuration of the API is changed, but the call is not affected | View Change Details |
2022-08-10 | The internal configuration of the API is changed, but the call is not affected | View Change Details |
2022-07-11 | Add Operation | View Change Details |