調用本介面通過音/視頻ID來擷取單個音視頻的標題、描述、時間長度、封面URL、狀態、建立時間、大小、截圖、分類和標籤等資訊。
介面說明
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
vod:GetVideoInfo |
get |
*全部資源
|
無 | 無 |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| VideoId |
string |
否 |
音/視頻 ID,僅支援傳入一個音/視頻 ID。可通過以下方式擷取:
|
9b73864d75f1d231e9001cd5f8**** |
| ReferenceId |
string |
否 |
自訂 ID,僅支援小寫字母、大寫字母、數字、橫線、底線,長度 6-64 位元。使用者維度唯一。 |
123-123 |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
返回結果。 |
||
| RequestId |
string |
請求 ID。 |
25818875-5F78-4AF6-D7393642CA58**** |
| Video |
object |
音/視頻資訊。 |
|
| StorageLocation |
string |
音/視頻儲存地址。 |
out-201703232251****.oss-cn-shanghai.aliyuncs.com |
| CreationTime |
string |
音/視頻建立時間。格式為:yyyy-MM-ddTHH:mm:ssZ(UTC 時間)。 |
2017-11-14T09:15:50Z |
| Status |
string |
音/視頻狀態。各狀態可執行檔操作及使用限制等詳細資料,請參見Status:音視頻狀態。取值:
|
Normal |
| CateId |
integer |
分類別識別碼。 |
781111**** |
| VideoId |
string |
音/視頻 ID。 |
9b73864d75f1d231e9001cd5f8**** |
| DownloadSwitch |
string |
離線下載開關狀態,開啟離線下載功能後,則允許移動端使用者通過阿里雲播放器將視頻緩衝至本地觀看。具體操作,請參見離線下載。取值:
|
on |
| Tags |
string |
音/視頻標籤。多個標籤之間使用半形逗號(,)分隔。 |
tag1, tag2 |
| ModificationTime |
string |
音/視頻的最後更新時間。格式為:yyyy-MM-ddTHH:mm:ssZ(UTC 時間)。 |
2017-11-14T10:15:50Z |
| RegionId |
string |
音/視頻儲存所在地區。 |
cn-shanghai |
| CustomMediaInfo |
string |
自訂媒資資訊。 說明
該參數已廢棄,調用 API 已不會返回該參數。 |
{"aaa":"test"} |
| CateName |
string |
分類名稱。 |
cate1 |
| Description |
string |
音/視頻描述。 |
Alibaba Cloud VOD video description |
| AppId |
string |
應用 ID。 |
app-**** |
| Size |
integer |
音/視頻源檔案大小。單位:位元組。 |
10897890 |
| CoverURL |
string |
音/視頻封面 URL。 |
https://example.aliyundoc.com/****.jpg |
| TemplateGroupId |
string |
轉碼模板組 ID。 |
9ae2af636ca64835b0c10412f448**** |
| Duration |
number |
音/視頻時間長度。單位:秒。 |
135.6 |
| Title |
string |
音/視頻標題。 |
Alibaba Cloud VOD Video Title |
| AuditStatus |
string |
音/視頻的終審結果。取值:
|
Normal |
| Snapshots |
object |
||
| Snapshot |
array |
視頻截圖 URL 數組。 |
|
|
string |
視頻截圖 URL 數組。 說明
本介面僅會返回視頻的封面截圖資料,通過視頻截圖功能截取的普通截圖、雪碧截圖、雪碧圖原始圖、WebVTT 截圖的截圖資料,請調用 ListSnapshots 介面查詢。 |
["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 |
媒資儲存類型。取值:
|
Standard |
| RestoreStatus |
string |
媒資解凍狀態。取值:
|
Success |
| RestoreExpiration |
string |
媒資解凍有效期間。 |
2023-03-30T10:14:14Z |
| UserData |
string |
自訂設定。為 JSON 字串,支援訊息回調、上傳加速等設定。更多資訊,請參見 UserData 。 |
{"MessageCallback":{"CallbackURL":"http://example.aliyundoc.com"},"Extend":{"localId":"*****","test":"www"}} |
| ReferenceId |
string |
自訂 ID,僅支援小寫字母、大寫字母、數字、橫線、底線,長度 6-64 位元。使用者維度唯一。 |
123-123 |
樣本
正常返回樣本
JSON格式
{
"RequestId": "25818875-5F78-4AF6-D7393642CA58****",
"Video": {
"StorageLocation": "out-201703232251****.oss-cn-shanghai.aliyuncs.com",
"CreationTime": "2017-11-14T09:15:50Z",
"Status": "Normal",
"CateId": 0,
"VideoId": "9b73864d75f1d231e9001cd5f8****",
"DownloadSwitch": "on",
"Tags": "tag1, tag2",
"ModificationTime": "2017-11-14T10:15:50Z",
"RegionId": "cn-shanghai",
"CustomMediaInfo": "{\"aaa\":\"test\"}",
"CateName": "cate1",
"Description": "Alibaba Cloud VOD video description",
"AppId": "app-****",
"Size": 10897890,
"CoverURL": "https://example.aliyundoc.com/****.jpg",
"TemplateGroupId": "9ae2af636ca64835b0c10412f448****",
"Duration": 135.6,
"Title": "Alibaba Cloud VOD Video Title",
"AuditStatus": "Normal",
"Snapshots": {
"Snapshot": [
"[\"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": "{\"MessageCallback\":{\"CallbackURL\":\"http://example.aliyundoc.com\"},\"Extend\":{\"localId\":\"*****\",\"test\":\"www\"}}",
"ReferenceId": "123-123"
}
}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。