Last update:2025-08-18 15:32:29
This API is used to retrieve basic metadata of specified audio and video resources stored on the CDNetworks Object Storage platform.
GET /<key>?op=avinfo2
HOST: <DownloadDomain>
| Parameter | Required | Description |
|---|---|---|
| Host | Yes | The download domain bound to the bucket |
| Parameter | Required | Description |
|---|---|---|
| op | Yes | Operation type. Must be avinfo2 (simplified audio/video information) |
If the request is successful, a JSON object in the following format will be returned:
{
"streams": [
{
"index": 0,
"codec_name": "h264",
"codec_type": "video",
"width": 480,
"height": 480,
"pix_fmt": "yuv420p",
"duration": "246.633333",
"bit_rate": "1173144",
"nb_frames": "7399",
"rotate": "90"
},
{
"index": 1,
"codec_name": "aac",
"codec_type": "audio",
"sample_rate": "44100",
"channels": 2,
"duration": "246.595918",
"bit_rate": "122396",
"nb_frames": "10620"
}
],
"format": {
"nb_streams": 2,
"format_name": "mov,mp4,m4a,3gp,3g2,mj2",
"duration": "246.639000",
"size": "40149865",
"bit_rate": "1302330"
}
}
For detailed field descriptions, please refer to avinfo Field Description.
Note: The
rotatefield is optional and only appears if the video stream contains rotation information.
If the request fails, a JSON object in the following format will be returned:
{
"code": "<code string>",
"message": "<message string>"
}
| Field | Required | Description |
|---|---|---|
| code | Yes | HTTP response code. See HTTP Response Status Codes |
| message | Yes | Error message indicating the reason for failure when retrieving simplified audio/video information |
curl -v "http://downloadDomain/1.mp4?op=avinfo2"