GetPublicMediaInfo - 获取公共版权媒资

根据ICE公共版权媒资的 mediaId,获取并返回媒资信息。接口返回的URL为版权媒资的试听或试看地址,合成时会使用正式素材。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

调试

授权信息

当前API暂无授权信息透出。

请求参数

名称类型必填描述示例值
MediaIdstring

IMS媒资ID

icepublic-****14e501538aeef0a3140176f6****

返回参数

名称类型描述示例值
object

Schema of Response

RequestIdstring

RequestId

******11-DB8D-4A9A-875B-275798******
MediaInfoobject

媒资信息

MediaIdstring

媒资ID

icepublic-****14e501538aeef0a3140176f6****
MediaBasicInfoobject

BasicInfo

MediaIdstring

MediaId

icepublic-****14e501538aeef0a3140176f6****
MediaTypestring

媒资媒体类型

video
BusinessTypestring

媒资业务类型

general
Sourcestring

来源

oss
Titlestring

标题

title
Descriptionstring

内容描述

description
Categorystring

分类

category
MediaTagsstring

标签

标签,tag1
CoverURLstring

封面地址

http://example-bucket.oss-cn-shanghai.aliyuncs.com/example.png?Expires=<ExpireTime>&OSSAccessKeyId=<OSSAccessKeyId>&Signature=<Signature>&security-token=<SecurityToken>
UserDatastring

用户数据

{"key":"value"}
Statusstring

资源状态

Normal
CreateTimestring

媒资创建时间

2020-12-26T04:11:08Z
ModifiedTimestring

媒资修改时间

2020-12-26T04:11:10Z
DeletedTimestring

媒资删除时间

2020-12-26T04:11:15Z
SpriteImagesstring

雪碧图

[{"bucket":"example-bucket","count":"32","iceJobId":"******83ec44d58b2069def2e******","location":"oss-cn-shanghai","snapshotRegular":"example/example-{Count}.jpg","spriteRegular":"example/example-{TileCount}.jpg","templateId":"******e438b14ff39293eaec25******","tileCount":"1"}]
DynamicMetaDataobject

公共媒资动态元数据

Typestring

类型。取值范围:

  • "ai": AI原始结果统一化处理后的AI数据
  • "user-defined": 用户自定义元数据
  • "system": 系统自带
system
Datastring

元数据json

{"AuditionUrl": "http://example-bucket.cdn.domain.com/example.mp4", "AuditionCount": 3}
FileInfoListarray

FileInfos

object
FileBasicInfoobject

文件基础信息,包含时长,大小等

FileNamestring

文件名

example.mp4
FileStatusstring

文件状态

Normal
FileTypestring

文件类型

source_file
FileSizestring

文件大小(字节)

27007
FileUrlstring

版权媒资试听或试看地址。

http://example-bucket.cdn.domain.com/example.mp4
Regionstring

文件存储区域

cn-shanghai
FormatNamestring

封装格式

mp4
Durationstring

时长

16.2
Bitratestring

码率

192.0
Widthstring

0
Heightstring

0
AudioStreamInfoListarray

音频流信息,一个媒资可能有多条音频流

object
Indexstring

音频流序号

1
CodecNamestring

编码格式简述名

aac
CodecLongNamestring

编码格式长述名

AAC (Advanced Audio Coding)
CodecTimeBasestring

编码时基

1/44100
CodecTagStringstring

编码格式标记文本

mp4a
CodecTagstring

编码格式标记

0x6134706d
Profilestring

编码预置

High
SampleFmtstring

采样格式

fltp
SampleRatestring

采样率

44100
Channelsstring

声道数

2
ChannelLayoutstring

声道输出样式

stereo
Timebasestring

时基

1/44100
StartTimestring

起始时间

0.000000
Durationstring

时长

16.2
Bitratestring

码率

192.0
Fpsstring

音频帧率

10
NumFramesstring

总帧数

162
Langstring

语言

und
VideoStreamInfoListarray

视频流信息,一个媒资可能有多条视频流

object
Indexstring

视频流序号

0
CodecNamestring

编码格式简述名

h264
CodecLongNamestring

编码格式长述名

H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
Profilestring

编码预置

High
CodecTimeBasestring

编码时基

1/48
CodecTagStringstring

编码格式标记文本

[0][0][0][0]
CodecTagstring

编码格式标记

0x0000
Widthstring

960
Heightstring

540
HasBFramesstring

是否有B帧

2
Sarstring

编码信号分辨率比

0:1
Darstring

编码显示分辨率比

0:1
PixFmtstring

像素格式

yuv420p
Levelstring

编码等级

30
Fpsstring

视频帧率

24.0
AvgFPSstring

平均帧率

24.0
Timebasestring

时基

1/12288
StartTimestring

起始时间

0.081706
Durationstring

时长

216.206706
Bitratestring

码率

1001.594
NumFramesstring

总帧数

5184
Langstring

语言

und
Rotatestring

旋转

0
Nb_framesstring

总帧数

5184
SubtitleStreamInfoListarray

字幕流信息,一个媒资可能有多条字幕流

object
Indexstring

字幕流序号

1
CodecNamestring

编码格式简述名

srt
CodecLongNamestring

编码格式长述名

SubRip Text
CodecTimeBasestring

编码时基

29.97
CodecTagStringstring

编码格式标记文本

unicode
CodecTagstring

编码格式标记

unicode
Timebasestring

时基

30
StartTimestring

起始时间

0
Durationstring

时长

1
Langstring

语言

und

示例

正常返回示例

JSON格式

{
  "RequestId": "******11-DB8D-4A9A-875B-275798******",
  "MediaInfo": {
    "MediaId": "icepublic-****14e501538aeef0a3140176f6****",
    "MediaBasicInfo": {
      "MediaId": "icepublic-****14e501538aeef0a3140176f6****",
      "MediaType": "video",
      "BusinessType": "general",
      "Source": "oss",
      "Title": "title",
      "Description": "description",
      "Category": "category",
      "MediaTags": "标签,tag1",
      "CoverURL": "http://example-bucket.oss-cn-shanghai.aliyuncs.com/example.png?Expires=<ExpireTime>&OSSAccessKeyId=<OSSAccessKeyId>&Signature=<Signature>&security-token=<SecurityToken>",
      "UserData": "{\"key\":\"value\"}",
      "Status": "Normal",
      "CreateTime": "2020-12-26T04:11:08Z",
      "ModifiedTime": "2020-12-26T04:11:10Z",
      "DeletedTime": "2020-12-26T04:11:15Z",
      "SpriteImages": "[{\"bucket\":\"example-bucket\",\"count\":\"32\",\"iceJobId\":\"******83ec44d58b2069def2e******\",\"location\":\"oss-cn-shanghai\",\"snapshotRegular\":\"example/example-{Count}.jpg\",\"spriteRegular\":\"example/example-{TileCount}.jpg\",\"templateId\":\"******e438b14ff39293eaec25******\",\"tileCount\":\"1\"}]"
    },
    "DynamicMetaData": {
      "Type": "system",
      "Data": "{\"AuditionUrl\": \"http://example-bucket.cdn.domain.com/example.mp4\", \"AuditionCount\": 3}"
    },
    "FileInfoList": [
      {
        "FileBasicInfo": {
          "FileName": "example.mp4",
          "FileStatus": "Normal",
          "FileType": "source_file",
          "FileSize": "27007",
          "FileUrl": "http://example-bucket.cdn.domain.com/example.mp4",
          "Region": "cn-shanghai",
          "FormatName": "mp4",
          "Duration": "16.2",
          "Bitrate": "192.0",
          "Width": "0",
          "Height": "0"
        },
        "AudioStreamInfoList": [
          {
            "Index": "1",
            "CodecName": "aac",
            "CodecLongName": "AAC (Advanced Audio Coding)",
            "CodecTimeBase": "1/44100",
            "CodecTagString": "mp4a",
            "CodecTag": "0x6134706d",
            "Profile": "High",
            "SampleFmt": "fltp",
            "SampleRate": "44100",
            "Channels": "2",
            "ChannelLayout": "stereo",
            "Timebase": "1/44100",
            "StartTime": "0.000000",
            "Duration": "16.2",
            "Bitrate": "192.0",
            "Fps": "10",
            "NumFrames": "162",
            "Lang": "und"
          }
        ],
        "VideoStreamInfoList": [
          {
            "Index": "0",
            "CodecName": "h264",
            "CodecLongName": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10",
            "Profile": "High",
            "CodecTimeBase": "1/48",
            "CodecTagString": "[0][0][0][0]",
            "CodecTag": "0x0000",
            "Width": "960",
            "Height": "540",
            "HasBFrames": "2",
            "Sar": "0:1",
            "Dar": "0:1",
            "PixFmt": "yuv420p",
            "Level": "30",
            "Fps": "24.0",
            "AvgFPS": "24.0",
            "Timebase": "1/12288",
            "StartTime": "0.081706",
            "Duration": "216.206706",
            "Bitrate": "1001.594",
            "NumFrames": "5184",
            "Lang": "und",
            "Rotate": "0",
            "Nb_frames": "5184"
          }
        ],
        "SubtitleStreamInfoList": [
          {
            "Index": "1",
            "CodecName": "srt",
            "CodecLongName": "SubRip Text",
            "CodecTimeBase": "29.97",
            "CodecTagString": "unicode",
            "CodecTag": "unicode",
            "Timebase": "30",
            "StartTime": "0",
            "Duration": "1",
            "Lang": "und"
          }
        ]
      }
    ]
  }
}

错误码

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
2021-11-25新增 OpenAPI
阿里云首页 智能媒体生产 相关技术圈