All Products
Search
Document Center

GetVideoInfos

Last Updated: Mar 04, 2019

Description

You can call this operation to obtain the basic information about multiple videos based on a list of video IDs. The basic information includes the title, description, duration, thumbnail URL, status, creation time, size, snapshots, category, and tags of each video.

Request parameters

NameTypeRequiredDescription
ActionStringYesThe operation that you want to perform. Set the value to GetVideoInfos.
VideoIdsStringYesThe list of video IDs. Separate multiple video IDs with a comma (,). You can enter a maximum of 20 video IDs.

Response parameters

NameTypeDescription
RequestId StringThe GUID generated by Alibaba Cloud for the request.
VideoList Video[]The video information list.
NonExistVideoIds String[]The list of video IDs that do not exist.

Examples

Sample requests

  1. http://vod.cn-shanghai.aliyuncs.com/?Action=GetVideoInfos&VideoIds=93ab850b4f6f44eab54b6e91d24d81d4,2567850b4f6f44eab54b6e91d24d8gdf&Format=JSON&<Common request parameters>

Note: For more information about common request parameters, see Common parameters.

Sample responses

JSON format

  1. {
  2. "RequestId": "25818875-5F78-4A13-BEF6-D7393642CA58",
  3. "VideoList": [{
  4. "VideoId": "93ab850b4f6f44eab54b6e91d24d81d4",
  5. "Title": "ApsaraVideo for VOD video title",
  6. "Description": "ApsaraVideo for VOD video description",
  7. "Duration": 135.6,
  8. "CoverURL": "https://image.example.com/coversample.jpg",
  9. "Status": "Normal",
  10. "CreationTime": "2017-06-26T05:38:48Z",
  11. "Size": 10897890,
  12. "Snapshots": [
  13. "http://image.example.com/snapshot/sample000001.jpg?auth_key=1498476426-0-0-f00b9455c49a423ce69cf4e273334f52",
  14. "http://image.example.com/snapshot/sample00002.jpg?auth_key=1498476426-0-0-f00b9455c49a423ce69cf4e272434f52",
  15. ...
  16. ],
  17. "CateId": 78,
  18. "CateName": "Category name",
  19. "Tags": "Tag 1,Tag 2"
  20. },
  21. ...
  22. ],
  23. "NonExistVideoIds":["b4039216985f4312a5382a4ed2884"]
  24. }

Error codes

The following table lists the error code that this operation can return. For more information, see Error codes.

Error codeError messageHTTP status codeDescription
InvalidVideo.NotFoundThe video does not exist.404The error message returned when the specified video does not exist.