Mengambil informasi dasar dan informasi file sumber dari beberapa aset media secara batch.
Deskripsi operasi
Anda dapat mengambil informasi hingga 20 file audio atau video sekaligus.
Setelah file audio atau video diunggah, ApsaraVideo VOD menganalisis file sumber yang diunggah. Oleh karena itu, informasi aset media dihasilkan secara asinkron. Anda dapat mengonfigurasi notifikasi event untuk event AudioVideoAnalysisComplete. Setelah Anda menerima notifikasi event AudioVideoAnalysisComplete, panggil operasi ini untuk mengambil informasi audio atau video.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
vod:BatchGetMediaInfos |
get |
*全部资源
|
None | None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| MediaIds |
string |
Yes |
ID aset media, yaitu ID audio/video (VideoId). Pisahkan beberapa ID dengan koma (,). Anda dapat menentukan hingga 20 ID. Anda dapat memperoleh ID dengan menggunakan metode berikut:
|
61ccbdb06fa83012be4d8083f6****,7d2fbc380b0e08e55f**** |
| ReferenceIds |
string |
No |
Daftar ID kustom. Pisahkan beberapa ID kustom dengan koma (,). Anda dapat menentukan hingga 20 ID. |
123-123,1234-1234 |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
ID permintaan. |
9E290613-04F4-47F4-795D30732077**** |
| NonExistMediaIds |
array |
Daftar ID aset media yang tidak ada. |
|
|
string |
Daftar ID aset media yang tidak ada. |
["bbc65bba53f6ed90de118a7849****"] |
|
| NonExistReferenceIds |
array |
Daftar ID kustom yang tidak ada. |
|
|
string |
Daftar ID kustom yang tidak ada. |
123-123 |
|
| ForbiddenMediaIds |
array |
Daftar ID aset media yang dilarang. Hal ini biasanya terjadi karena Anda tidak memiliki izin untuk operasi multi-aplikasi. Untuk informasi lebih lanjut, lihat Multi-application. |
|
|
string |
Daftar ID aset media yang dilarang. Hal ini biasanya terjadi karena Anda tidak memiliki izin untuk operasi multi-aplikasi. Untuk informasi lebih lanjut, lihat Multi-application. |
["bbc65bba53f6ed90de118a7849****"] |
|
| MediaInfos |
array<object> |
Daftar aset media. |
|
|
array<object> |
Daftar aset media. |
||
| MediaId |
string |
ID aset media. |
10a5fa364a5b71ef89246733a78e**** |
| MediaInfo |
object |
Informasi dasar aset media. |
|
| StorageLocation |
string |
The storage address of the audio or video file. |
outin-***.oss-cn-shanghai.aliyuncs.com |
| CreationTime |
string |
The time when the audio or video file was created. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2017-11-14T09:15:50Z |
| Status |
string |
The status of the video. Valid values:
|
Normal |
| CateId |
integer |
The category ID. |
781111**** |
| MediaId |
string |
The ID of the media asset. |
7753d144efd74d6c45fe0570**** |
| DownloadSwitch |
string |
The status of the offline download switch. After you enable offline download, users can use ApsaraVideo Player to cache videos to their local devices for offline viewing. For more information, see Offline download. Valid values:
|
on |
| Tags |
string |
The tags of the audio or video file. Separate multiple tags with commas (,). |
tag1, tag2 |
| ModificationTime |
string |
The time when the audio or video file was last updated. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2017-06-26T06:38:48Z |
| CateName |
string |
The category name. |
cate1 |
| Description |
string |
The description of the audio or video file. |
Alibaba Cloud VOD video description |
| AppId |
string |
The application ID. |
app-**** |
| CoverURL |
string |
The URL of the thumbnail. |
https://example.aliyundoc.com/****.jpg |
| TemplateGroupId |
string |
The ID of the transcoding template group. |
b4039216985f4312a5382a4ed**** |
| Title |
string |
The title of the audio or video file. |
Alibaba Cloud VOD Video Title |
| Snapshots |
array |
An array of video snapshot URLs. |
|
|
string |
An array of video snapshot URLs. Catatan
This operation returns only the data of video thumbnails. To query the data of normal snapshots, sprites, original sprite images, and WebVTT snapshots that are captured using the snapshot feature, call the ListSnapshots operation. |
["http://example.aliyundoc.com/snapshot/****.jpg?auth_key=1498476426-0-0-f00b9455c49a423ce69cf4e27333****","http://example.aliyundoc.com/snapshot/****.jpg?auth_key=1498476426-0-0-f00b9455c49a423ce69cf4e27243****",...] |
|
| StorageClass |
string |
The storage class of the media asset. Valid values:
|
Standard |
| RestoreStatus |
string |
The restoration status of the media asset. Valid values:
|
Success |
| RestoreExpiration |
string |
The expiration time of the restored media asset. |
2023-03-30T10:14:14Z |
| UserData |
string |
The custom parameters. |
{"Extend":"xxx","MessageCallback":"xxx"} |
| ReferenceId |
string |
The custom ID. The ID can contain lowercase letters, uppercase letters, digits, hyphens (-), and underscores (_). The ID must be 6 to 64 characters in length and unique for a user. |
123-123 |
| MezzanineInfo |
object |
Informasi file sumber. |
|
| CreationTime |
string |
The time when the file was created. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2017-11-14T09:15:50Z |
| Status |
string |
The status of the file. Valid values:
|
Normal |
| FileURL |
string |
The URL of the source file. |
http://example-bucket-****.oss-cn-shanghai.aliyuncs.com/27ffc438-164h67f57ef-0005-6884-51a-1****.mp4 |
| MediaId |
string |
The ID of the media asset. |
1f1a6fc03ca04814031b8a6559e**** |
| Height |
integer |
The height of the file in pixels (px). |
540 |
| Bitrate |
string |
The bitrate of the file in Kbps. |
771.2280 |
| FileName |
string |
The name of the file. |
27ffc438-164h67f57ef-0005-6884-51a-1****.mp4 |
| Width |
integer |
The width of the file in pixels (px). |
960 |
| Size |
integer |
The size of the file in bytes. |
4096477 |
| Duration |
string |
The duration of the file in seconds. |
42.4930 |
| Fps |
string |
The frame rate of the file in frames per second. |
25.0000 |
| AudioStreamList |
array<object> |
The information about the audio stream. |
|
|
object |
The details of the audio stream. |
||
| Index |
string |
The sequence number of the audio stream. This number indicates the position of the audio stream in the media stream. |
0 |
| Timebase |
string |
The time base. |
0.000000 |
| SampleFmt |
string |
The sampling format. |
fltp |
| SampleRate |
string |
The sample rate. |
44100 |
| ChannelLayout |
string |
The output layout of the sound channel. Valid values:
|
mono |
| Lang |
string |
The language. |
und |
| CodecLongName |
string |
The long name of the encoding format. |
AAC (Advanced Audio Coding) |
| Channels |
string |
The number of sound channels. |
1 |
| NumFrames |
string |
The total number of frames. |
1 |
| Bitrate |
string |
The bitrate. |
62.885 |
| CodecTagString |
string |
The tag text of the encoding format. |
mp4a |
| StartTime |
string |
The start time. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2017-01-11T12:00:00Z |
| CodecName |
string |
The short name of the encoding format. |
aac |
| Duration |
string |
The duration. |
3.227574 |
| CodecTag |
string |
The tag of the encoding format. |
0x6134706d |
| CodecTimeBase |
string |
The codec time base. |
1/44100 |
| VideoStreamList |
array<object> |
The information about the video stream. |
|
|
object |
The details of the video stream. |
||
| Timebase |
string |
The time base. |
0.000000 |
| Index |
string |
The sequence number of the video stream. This number indicates the position of the video stream in the media stream. |
1 |
| AvgFPS |
string |
The average frame rate. |
30.0 |
| PixFmt |
string |
The pixel format. |
yuv420p |
| Lang |
string |
The language. |
und |
| Sar |
string |
The sample aspect ratio (SAR). |
0:1 |
| Height |
string |
The height of the video. |
320 |
| CodecLongName |
string |
The long name of the encoding format. |
H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 |
| NumFrames |
string |
The total number of frames. |
0 |
| Bitrate |
string |
The bitrate of the file in Kbps. |
500 |
| Rotate |
string |
The rotation angle of the video. Valid values: [0, 360). |
90 |
| CodecTagString |
string |
The tag text of the encoding format. |
avc1 |
| HasBFrames |
string |
Indicates whether B-frames exist. |
0 |
| Profile |
string |
The codec profile. |
Main |
| StartTime |
string |
The start time. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2017-01-11T12:00:00Z |
| Dar |
string |
The display aspect ratio (DAR). |
0:1 |
| CodecName |
string |
The short name of the encoding format. |
h264 |
| Width |
string |
The width of the video. |
568 |
| Duration |
string |
The duration. |
3.166667 |
| Fps |
string |
The frame rate. |
30.0 |
| CodecTag |
string |
The tag of the encoding format. |
0x31637661 |
| CodecTimeBase |
string |
The codec time base. |
1/60 |
| Level |
string |
The encoding level. |
30 |
| HDRType |
string |
The High Dynamic Range (HDR) type of the video stream. |
HDR |
| FileMD5 |
string |
||
| PlayInfoList |
array<object> |
Informasi pemutaran (informasi aliran) file audio/video. |
|
|
object |
Informasi detail file audio/video. |
||
| CreationTime |
string |
The time when the stream was created. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2022-04-18T07:37:15Z |
| Status |
string |
The status of the media stream. Valid values:
|
Normal |
| Specification |
string |
The output specifications of audio and video transcoding. For more information about the valid values and descriptions, see Output specifications: Specification. |
H264.LD |
| NarrowBandType |
string |
The transcoding type. Valid values:
|
0 |
| Height |
integer |
The height of the media stream in pixels (px). |
640 |
| Bitrate |
string |
The bitrate of the media stream in Kbps. |
450.878 |
| ModificationTime |
string |
The time when the stream was last updated. The time is in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
2022-04-20T06:32:19Z |
| WatermarkId |
string |
The ID of the watermark template that is associated with the media stream. |
dgfn26457856**** |
| Encrypt |
integer |
Indicates whether the media stream is encrypted. Valid values:
|
1 |
| Definition |
string |
The definition of the video stream. Valid values:
|
LD |
| EncryptType |
string |
The encryption type of the media stream. Valid values:
Catatan
If the encryption type is AliyunVoDEncryption, you can play the stream only using ApsaraVideo Player SDK. |
AliyunVoDEncryption |
| EncryptMode |
string |
The encryption mode of the media stream. Valid values:
Catatan
If the encryption mode is License, you can play the stream only using ApsaraVideo Player SDK. |
License |
| StreamType |
string |
The type of the media stream. If the media stream is a video stream, the value is video. If the media stream is an audio-only stream, the value is audio. |
video |
| JobId |
string |
The ID of the transcoding job for the media stream. This ID serves as the unique identifier of the media stream. |
80e9c6580e754a798c3c19c59b16**** |
| Size |
integer |
The size of the media stream in bytes. |
418112 |
| Width |
integer |
The width of the media stream in pixels (px). |
360 |
| Fps |
string |
The frame rate of the media stream in frames per second. |
25 |
| Duration |
string |
The duration of the media stream in seconds. |
9.0464 |
| PlayURL |
string |
The playback URL of the video stream. |
https://example.aliyundoc.com/d52ee123f331466aabf6ab32a93d****/a777f9e24e6e47a2a942467d5c38ea37-8ee8e04293c6657fdda282bc422704****.m3u8 |
| Format |
string |
The format of the media stream.
|
m3u8 |
| HDRType |
string |
The HDR type of the media stream. Valid values:
|
HLG |
| BitDepth |
integer |
The color depth. The value is an integer. |
8 |
| JobType |
integer |
The type of the digital watermark. Valid values:
|
2 |
| JobExt |
string |
The custom watermark information for the copyright watermark. This parameter is returned only when |
CopyrightMarkTest |
| CodecName |
string |
The short name of the encoding format. |
h264 |
| TemplateId |
string |
The ID of the transcoding template. |
a86a4338dd2e83da45154004a541**** |
| TemplateGroupId |
string |
The ID of the transcoding template group. |
fb0716154b21a4ecb5b70a26ccc8**** |
Contoh
Respons sukses
JSONformat
{
"RequestId": "9E290613-04F4-47F4-795D30732077****",
"NonExistMediaIds": [
"[\"bbc65bba53f6ed90de118a7849****\"]"
],
"NonExistReferenceIds": [
"123-123"
],
"ForbiddenMediaIds": [
"[\"bbc65bba53f6ed90de118a7849****\"]"
],
"MediaInfos": [
{
"MediaId": "10a5fa364a5b71ef89246733a78e****",
"MediaInfo": {
"StorageLocation": "outin-***.oss-cn-shanghai.aliyuncs.com",
"CreationTime": "2017-11-14T09:15:50Z",
"Status": "Normal",
"CateId": 0,
"MediaId": "7753d144efd74d6c45fe0570****",
"DownloadSwitch": "on",
"Tags": "tag1, tag2",
"ModificationTime": "2017-06-26T06:38:48Z",
"CateName": "cate1",
"Description": "Alibaba Cloud VOD video description",
"AppId": "app-****",
"CoverURL": "https://example.aliyundoc.com/****.jpg",
"TemplateGroupId": "b4039216985f4312a5382a4ed****",
"Title": "Alibaba Cloud VOD Video Title",
"Snapshots": [
"[\"http://example.aliyundoc.com/snapshot/****.jpg?auth_key=1498476426-0-0-f00b9455c49a423ce69cf4e27333****\",\"http://example.aliyundoc.com/snapshot/****.jpg?auth_key=1498476426-0-0-f00b9455c49a423ce69cf4e27243****\",...]"
],
"StorageClass": "Standard",
"RestoreStatus": "Success",
"RestoreExpiration": "2023-03-30T10:14:14Z",
"UserData": "{\"Extend\":\"xxx\",\"MessageCallback\":\"xxx\"}",
"ReferenceId": "123-123"
},
"MezzanineInfo": {
"CreationTime": "2017-11-14T09:15:50Z",
"Status": "Normal",
"FileURL": "http://example-bucket-****.oss-cn-shanghai.aliyuncs.com/27ffc438-164h67f57ef-0005-6884-51a-1****.mp4",
"MediaId": "1f1a6fc03ca04814031b8a6559e****",
"Height": 540,
"Bitrate": "771.2280",
"FileName": "27ffc438-164h67f57ef-0005-6884-51a-1****.mp4\n",
"Width": 960,
"Size": 4096477,
"Duration": "42.4930",
"Fps": "25.0000",
"AudioStreamList": [
{
"Index": "0",
"Timebase": "0.000000",
"SampleFmt": "fltp",
"SampleRate": "44100",
"ChannelLayout": "mono",
"Lang": "und",
"CodecLongName": "AAC (Advanced Audio Coding)\n",
"Channels": "1",
"NumFrames": "1",
"Bitrate": "62.885",
"CodecTagString": "mp4a",
"StartTime": "2017-01-11T12:00:00Z",
"CodecName": "aac",
"Duration": "3.227574",
"CodecTag": "0x6134706d",
"CodecTimeBase": "1/44100"
}
],
"VideoStreamList": [
{
"Timebase": "0.000000",
"Index": "1",
"AvgFPS": "30.0",
"PixFmt": "yuv420p",
"Lang": "und",
"Sar": "0:1",
"Height": "320",
"CodecLongName": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10",
"NumFrames": "0",
"Bitrate": "500",
"Rotate": "90",
"CodecTagString": "avc1",
"HasBFrames": "0",
"Profile": "Main",
"StartTime": "2017-01-11T12:00:00Z",
"Dar": "0:1",
"CodecName": "h264",
"Width": "568",
"Duration": "3.166667",
"Fps": "30.0",
"CodecTag": "0x31637661",
"CodecTimeBase": "1/60",
"Level": "30",
"HDRType": "HDR"
}
],
"FileMD5": ""
},
"PlayInfoList": [
{
"CreationTime": "2022-04-18T07:37:15Z\n",
"Status": "Normal",
"Specification": "H264.LD",
"NarrowBandType": "0",
"Height": 640,
"Bitrate": "450.878",
"ModificationTime": "2022-04-20T06:32:19Z",
"WatermarkId": "dgfn26457856****",
"Encrypt": 1,
"Definition": "LD",
"EncryptType": "AliyunVoDEncryption",
"EncryptMode": "License",
"StreamType": "video",
"JobId": "80e9c6580e754a798c3c19c59b16****",
"Size": 418112,
"Width": 360,
"Fps": "25",
"Duration": "9.0464",
"PlayURL": "https://example.aliyundoc.com/d52ee123f331466aabf6ab32a93d****/a777f9e24e6e47a2a942467d5c38ea37-8ee8e04293c6657fdda282bc422704****.m3u8",
"Format": "m3u8",
"HDRType": "HLG",
"BitDepth": 8,
"JobType": 2,
"JobExt": "CopyrightMarkTest",
"CodecName": "h264",
"TemplateId": "a86a4338dd2e83da45154004a541****",
"TemplateGroupId": "fb0716154b21a4ecb5b70a26ccc8****"
}
]
}
]
}
Kode kesalahan
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.