The API returns comprehensive metadata for audio and video files, primarily within the streams (stream information) and format (file format information) fields. This document describes the fields included in the API response.
Audio and Video Stream Information – streams Field
Each media stream corresponds to an item within the streams array.
Common Fields
| Field Name |
Description |
| avg_frame_rate |
Average frame rate |
| bit_rate |
Bitrate |
| codec_long_name |
Full codec name |
| codec_name |
Codec name |
| codec_tag |
Codec tag |
| codec_tag_string |
Codec tag string |
| codec_time_base |
Codec frame duration |
| codec_type |
Codec type |
| display_aspect_ratio |
Display aspect ratio |
| disposition |
Disposition information (see below) |
| duration |
Stream duration |
| rotate |
Rotation information |
| duration_ts |
Total frame time |
| has_b_frames |
B-frame buffer size |
| height |
Video height |
| index |
Stream index |
| level |
Level |
| nb_frames |
Number of frames |
| pix_fmt |
Pixel format |
| profile |
Profile |
| r_frame_rate |
Real base frame rate |
| sample_aspect_ratio |
Sample aspect ratio |
| start_pts |
Start PTS (presentation timestamp) |
| start_time |
First frame time |
| tag |
Tag information (see below) |
| time_base |
Frame duration |
| width |
Video width |
disposition Field Description
| Field |
Description |
| attached_pic |
Thumbnail/attached image |
| clean_effects |
Clean effects |
| comment |
Comment |
| default |
Default stream |
| dub |
Dub |
| forced |
Forced stream |
| hearing_impaired |
Hearing-impaired stream |
| karaoke |
Karaoke track |
| lyrics |
Lyrics track |
| original |
Original stream |
| visual_impaired |
Visually-impaired stream |
tag Field Description
| Field |
Description |
| creation_time |
Creation time |
| encoder |
Encoder name |
| handler_name |
Handler name |
| language |
Language |
Audio Stream-Specific Fields
| Field Name |
Description |
| bits_per_sample |
Bits per sample |
| channels |
Number of channels |
| sample_fmt |
Sample format |
| sample_rate |
Sample rate |
File Format Information – format Field
This field contains information about the overall media file.
Field Descriptions
| Field Name |
Description |
| bit_rate |
Bitrate |
| duration |
Duration |
| format_long_name |
Full format name |
| format_name |
Format short name |
| nb_programs |
Number of programs |
| nb_streams |
Number of streams |
| probe_score |
Probe score (format detection) |
| size |
File size |
| start_time |
First frame time |
| tag |
Tag information (see below) |
tag Field Description
| Field |
Description |
| compatible_brands |
Compatible brands |
| creation_time |
Creation time |
| major_brand |
Major brand |
| minor_version |
Minor version |
Sample Response
{
"streams": [
{
"avg_frame_rate": <average frame rate>,
"bit_rate": <bitrate>,
"codec_long_name": <full codec name>,
"codec_name": <codec name>,
"codec_tag": <codec tag>,
"codec_tag_string": <codec tag string>,
"codec_time_base": <codec frame duration>,
"codec_type": <codec type>,
"display_aspect_ratio": <display aspect ratio>,
"disposition": { // disposition information
"attached_pic": 0,
"clean_effects": 0,
"comment": 0,
"default": 1,
"dub": 0,
"forced": 0,
"hearing_impaired": 0,
"karaoke": 0,
"lyrics": 0,
"original": 0,
"visual_impaired": 0
},
"duration": <duration>,
"rotate": <rotation information>,
"duration_ts": <total frame time>,
"has_b_frames": <B-frame buffer size>,
"height": <height>,
"index": <stream index>,
"level": <level>,
"nb_frames": <number of frames>,
"pix_fmt": <pixel format>,
"profile": <profile>,
"r_frame_rate": <real base frame rate>,
"sample_aspect_ratio": <sample aspect ratio>,
"start_pts": <start PTS>,
"start_time": <first frame time>,
"tag": { // tag information
"creation_time": <creation time>,
"encoder": <encoder name>,
"handler_name": <handler name>,
"language": <language>
},
"time_base": <frame duration>,
"width": <width>
},
{
"avg_frame_rate": <average frame rate>,
"bit_rate": <bitrate>,
"bits_per_sample": <bits per sample>,
"channels": <channels>,
"codec_long_name": <full codec name>,
"codec_name": <codec name>,
"codec_tag": <codec tag>,
"codec_tag_string": <codec tag string>,
"codec_time_base": <codec frame duration>,
"codec_type": <codec type>,
"disposition": { // disposition information
"attached_pic": 0,
"clean_effects": 0,
"comment": 0,
"default": 1,
"dub": 0,
"forced": 0,
"hearing_impaired": 0,
"karaoke": 0,
"lyrics": 0,
"original": 0,
"visual_impaired": 0
},
"duration": <duration>,
"duration_ts": <total frame time>,
"index": <stream index>,
"nb_frames": <number of frames>,
"profile": <profile>,
"r_frame_rate": <real base frame rate>,
"sample_fmt": <sample format>,
"sample_rate": <sample rate>,
"start_pts": <start PTS>,
"start_time": <first frame time>,
"tag": { // tag information
"creation_time": <creation time>,
"handler_name": <handler name>,
"language": <language>
},
"time_base": <frame duration>
}
],
"format": {
"bit_rate": <bitrate>,
"duration": <duration>,
"format_long_name": <full format name>,
"format_name": <format name>,
"nb_programs": <number of programs>,
"nb_streams": <number of streams>,
"probe_score": <probe score>,
"size": <file size>,
"start_time": <first frame time>,
"tag": { // tag information
"compatible_brands": <compatible brands>,
"creation_time": <creation time>,
"major_brand": <major brand>,
"minor_version": <minor version>
}
}
}