GetVideoList

Update time: 2024-07-29 17:13:16

Call the getVideoList client to get a list of uploaded videos (including: upload time, video name, video ID, video status, etc.)

  • Single user trigger frequency: 300/5min
  • Applicable Products: Cloud VoD

Request

Body Params

NameDescription
createUserString
Create a user. The value is blank by default. Multiple entries are allowed. They are separated by commas (,) and cannot start or end with a comma. This parameter is restricted by permissions. Only sub-accounts or users with special permissions can be queried.
startTimeString
The start time is in the format of 2016-01-01 12:00:00. Query videos by creation time range.
endTimeString
The query end time is in the format of 2016-01-01 12:00:00. This parameter is used to query videos in the creation period, which is smaller than the current query time.
videoNameString
Video name, used to filter videos, support fuzzy matching;
videoIdString
Video ID, used to filter videos;
videoStatusInteger
Video status, used to filter videos
transcodeStateInteger
Authorized play is not enabled. Procedure
videoClassificationString
Separate video categories with commas (,).
listOrderInteger
List order
pageIndexInteger
Page of the video list. The value starts from 1. The default value is 1. The product of pageIndex and pageSize must be less than 100000.
pageSizeInteger
Average number of videos per page. The value ranges from 1 to 50. The default value is 10. The product of pageIndex and pageSize must be less than 100000.

Response

Body Params

NameDescription
codeInteger
200 success
messageString
Successful operation
dataObject
Return data
videoTotalInteger
The number of records of the video list information currently returned. Note that the number of records returned here is only the number of records of the current page.
videoListInfoList
videoListInfo
videoNameString
videoName
videoIdString
videoId
createUserString
createUser
encryptInteger
Whether to encrypt transcoding files. Value range: 0(unencrypted) 1(encrypted)
videoSizeString
The space occupied by the video, and the total space used by the video and its transcoding
videoDurationString
videoDuration
createTimeString
createTime
uploadTimeString
uploadTime
updateTimeString
updateTime
videoDescriptionString
videoDescription
videoClassificationString
videoClassification
imageUrlString
imageUrl
publishDomainString
publishDomain
playerNameString
playerName
playerIdString
playerId
videoStateInteger
Video state Value range: 0(enable) 1(mask)
transcodeStateInteger
If authorized play is not enabled, the video transcoding status ranges from: 1(transcoded) 2(no transcoding) 3(in transcoding) 4(Transcoding fails) Value range of transcoding status when the Authorized Play (video encryption) function is enabled: 1(encrypted transcoding) 2(non-encrypted transcoding) 3(in transcoding) 4(Transcoding fails) 5(not transcoded)
videoSourceCodeInteger
Video source Value range: 0(other) 1(Upload) 2 (Live streaming to recording) 3 (Video pull) 4 (Video cutting) 5 (Video Stitching) 6 (edge pull recording) 10 (universal version of live broadcasting to recording) 11 (Uploading SDK) 12 (Upload tool)
videoResolutionsList
Video resolution and other information
clarityInteger
Clarity. Value range: 1(original painting) 2(fluency) 3(standard definition) 4(HD) 5(Super clear) -99(record file)
serverTypeInteger
Terminal type. Value range: -1(Source video) 0(PC) 1(mobile terminal)
heightInteger
height
widthInteger
width
fileSizeLong
fileSize

Error code

Error code(code)Description(message)HTTP statusSemantic
1512The start time is incorrect. Enter the following format: YYYY-MM-DD HH:mm:ss200The start time is incorrect. Enter the following format: YYYY-MM-DD HH:mm:ss
1513The end time is incorrect. Enter the following format: YYYY-MM-DD HH:mm:ss200The end time is incorrect. Enter the following format: YYYY-MM-DD HH:mm:ss
1519Ensure that the start time is less than the end time200Ensure that the start time is less than the end time
1518The video input contains special characters200The video input contains special characters
1504videoId contains special characters200videoId contains special characters
1515videoStatus can only enter 0 or 1200videoStatus can only enter 0 or 1
1516transcodeState The value can be an integer ranging from 1 to 5200transcodeState The value can be an integer ranging from 1 to 5
1517videoClassification can only contain Chinese, English, letters, and commas200videoClassification can only contain Chinese, English, letters, and commas
1320The listOrder can only be 0 or 1200The listOrder can only be 0 or 1
1321The listOrder cannot be empty200The listOrder cannot be empty
1322pageIndex can only be an integer greater than 0200pageIndex can only be an integer greater than 0
1323pageSize can only be integers from 1 to 50200pageSize can only be integers from 1 to 50
1324The pageIndex value is too large200The pageIndex value is too large

Example

JSON
JSON
Request example
Copy Copy success
#!/bin/bash
username='example_username'
apiKey='example_apiKey'
date=`env LANG="en_US.UTF-8" date -u "+%a, %d %b %Y %H:%M:%S GMT"`
password=`echo -en "$date" | openssl dgst -sha1 -hmac $apiKey -binary | openssl enc -base64`
curl -i --url "https://api.cdnetworks.com/vod/videoManage/getVideoList" \
-X "POST" \
-u "$username:$password" \
-H "Date: $date" \
-H "x-cnc-auth-method: BASIC" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
	"createUser":"testUser",
	"startTime":"2016-01-01 12:00:00",
	"endTime":"2016-01-01 12:00:00",
	"videoName":"fileName",
	"videoId":"aaaaabbbbbccccc",
	"videoStatus":"0",
	"transcodeState":"1",
	"videoClassification":"videoClassification1,videoClassification2",
	"listOrder":"1",
	"pageIndex":"1",
	"pageSize":"10"
}'
Response example
Copy Copy success
{
    "code": 200,
    "data": {
        "videoListInfo": [
            {
                "createUser": "testUser",
                "encrypt": 0,
                "playerId": "DF2DAF233DDA",
                "playerName": "name",
                "imageUrl": "http://ovptest.haplat.net//live/201708/4101630234a74ee8864e56ea88e5d290_20170801171220/cloudv-cover/9B0F7BA8BCB9D056D4C24ADDBF821D10.jpg",
                "publishDomain": "ovptest.haplat.net",
                "transcodeState": "5",
                "updateTime": "1501578874",
                "uploadTime": "1501578866",
                "videoClassification": "no",
                "videoDescription": "",
                "videoDuration": "36",
                "videoId": "9B0F7BA8BCB9D056D4C24ADDBF821D10",
                "videoName": "creattest_20170801171220",
                "videoResolutions": [
                    {
                        "clarity": -99,
                        "fileSize": 5579209,
                        "height": 768,
                        "serverType": -1,
                        "width": 1364
                    },
                    {
                        "clarity": 1,
                        "fileSize": 5573951,
                        "height": 768,
                        "serverType": -1,
                        "width": 1364
                    }
                ],
                "videoSize": "11153160",
                "videoSourceCode": 2,
                "videoState": "0"
            },
            {
                "createUser": "testUser",
                "encrypt": 0,
                "flashAutoPlay": 1,
                "flashImageRatio": 0,
                "flashPlayerId": "DF2DAF233DDA",
                "flashPlayerName": "name",
                "imageUrl": "http://ovptest.haplat.net//live/201708/4101630234a74ee8864e56ea88e5d290_20170801171104/cloudv-cover/E869FC95F3C7493ED56E8751C4AA7BEE.jpg",
                "publishDomain": "ovptest.haplat.net",
                "transcodeState": "5",
                "updateTime": "1501578796",
                "uploadTime": "1501578790",
                "videoClassification": "no",
                "videoDescription": "",
                "videoDuration": "15",
                "videoId": "E869FC95F3C7493ED56E8751C4AA7BEE",
                "videoName": "creattest_20170801171104",
                "videoResolutions": [
                    {
                        "clarity": -99,
                        "fileSize": 2533394,
                        "height": 768,
                        "serverType": -1,
                        "width": 1364
                    },
                    {
                        "clarity": 1,
                        "fileSize": 2531523,
                        "height": 768,
                        "serverType": -1,
                        "width": 1364
                    }
                ],
                "videoSize": "5064917",
                "videoSourceCode": 2,
                "videoState": "0"
            }
        ],
        "videoTotal": 2
    },
    "message": "Operation succeeded"
}
Is the content of this document helpful to you?
Yes
I have suggestion
Submitted successfully! Thank you very much for your feedback, we will continue to strive to do better!