提交媒体信息作业。调用本接口之后媒体处理MPS会对输入文件进行媒体信息分析,返回输入文件的媒体信息。
接口说明
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
下表是API对应的授权信息,可以在RAM权限策略语句的Action
元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:
- 操作:是指具体的权限点。
- 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
- 资源类型:是指操作中支持授权的资源类型。具体说明如下:
- 对于必选的资源类型,用背景高亮的方式表示。
- 对于不支持资源级授权的操作,用
全部资源
表示。
- 条件关键字:是指云产品自身定义的条件关键字。
- 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作 | 访问级别 | 资源类型 | 条件关键字 | 关联操作 |
---|---|---|---|---|
mts:SubmitMediaInfoJob | create |
|
| 无 |
请求参数
名称 | 类型 | 必填 | 描述 | 示例值 |
---|---|---|---|---|
Input | string | 是 | 作业输入。详细说明请参见 Input 详情。 说明
| {"Bucket":"example-bucket","Location":"example-location","Object":"example%2Fexample.flv"} |
UserData | string | 否 | 用户自定义数据。可以使用中英文、数字、中划线(-)等,不能以特殊符号开头,最大长度 1024 个字节。 | testid-001 |
PipelineId | string | 否 | 88c6ca184c0e432bbf5b665e2a15**** | |
Async | boolean | 否 | 是否发起异步作业。取值:
| true |
返回参数
示例
正常返回示例
JSON
格式
{
"MediaInfoJob": {
"CreationTime": "2014-01-10T12:00:00Z",
"State": "Analyzing",
"JobId": "23ca1d184c0e4341e5b665e2a12****",
"UserData": "testid-001",
"Code": "InvalidParameter.JsonObjectFormatInvalid",
"Message": "The parameter ”*” does not conform to the JSON Object specification",
"PipelineId": "88c6ca184c0e432bbf5b665e2a15****",
"Async": true,
"Input": {
"Object": "example.flv",
"Location": "example-location",
"Bucket": "example-bucket"
},
"MNSMessageResult": {
"MessageId": "16f01ad6175e4230ac42bb5182cd****",
"ErrorMessage": "InvalidParameter.JsonObjectFormatInvalid",
"ErrorCode": "The parameter \\\"Input\\\" does not conform to the JSON Object specification"
},
"Properties": {
"Width": "1920",
"Height": "1080",
"Duration": "17.226000",
"Fps": "25",
"Bitrate": "1630.045",
"FileFormat": "QuickTime/MOV",
"Streams": {
"VideoStreamList": {
"VideoStream": [
{
"Sar": "1:1",
"Height": "1080",
"CodecTagString": "avc1",
"NetworkCost": {
"PreloadTime": "8",
"AvgBitrate": "300.34",
"CostBandwidth": "10"
},
"Width": "1920",
"Index": "1",
"Timebase": "1/24000",
"AvgFPS": "23.976025",
"PixFmt": "yuv420p",
"Lang": "eng",
"CodecLongName": "H.264/AVC/MPEG-4 AVC/MPEG-4 part 10",
"NumFrames": "100",
"Rotate": "90",
"Bitrate": "1496.46",
"HasBFrames": "0",
"Profile": "High",
"StartTime": "0.042000",
"Dar": "16:9",
"CodecName": "h264",
"Duration": "17.225542",
"Fps": "25",
"CodecTag": "0x31637661",
"CodecTimeBase": "1001/48000",
"Level": "41",
"ColorRange": "700",
"ColorTransfer": "R255 G83 B170",
"ColorPrimaries": "700"
}
]
},
"AudioStreamList": {
"AudioStream": [
{
"Timebase": "1/44100",
"Index": "1",
"SampleFmt": "fltp",
"ChannelLayout": "stereo",
"Lang": "eng",
"Samplerate": "44100",
"CodecLongName": "AAC (Advanced Audio Coding)",
"Channels": "2",
"NumFrames": "123",
"Bitrate": "128.806",
"CodecTagString": "mp4a",
"StartTime": "0.000000",
"CodecName": "aac",
"Duration": "17.159546",
"CodecTag": "0x6134706d",
"CodecTimeBase": "1/44100"
}
]
},
"SubtitleStreamList": {
"SubtitleStream": [
{
"Timebase": "1/1000",
"Index": "3",
"StartTime": "0.000000",
"CodecName": "ass",
"Lang": "eng",
"CodecLongName": "ASS (Advanced SSA) subtitle",
"Duration": "1370.116000",
"CodecTag": "0x0000",
"CodecTimeBase": "0/1",
"CodecTagString": "[0][0][0][0]"
}
]
}
},
"Format": {
"StartTime": "0.000000",
"NumPrograms": "0",
"Size": "3509895",
"NumStreams": "2",
"FormatLongName": "QuickTime/MOV",
"Duration": "17.226000",
"Bitrate": "1630.045",
"FormatName": "mov"
},
"FileSize": "3509895"
}
},
"RequestId": "62D9BE16-B7D5-550C-A482-7A0F60E09877"
}
错误码
访问错误中心查看更多错误码。
变更历史
变更时间 | 变更内容概要 | 操作 |
---|---|---|
2021-05-18 | 新增 OpenAPI | 查看变更详情 |