Returns basic source details for your input.
Request
<?xml version="1.0"?>
<query>
<userid>[UserID]</userid>
<userkey>[UserKey]</userkey>
<action>GetMediaInfo</action>
<mediaid>[MediaID]</mediaid> <!-- required -->
</query>
{
"query": {
"userid": "[UserID]",
"userkey": "[UserKey]",
"action": "GetMediaInfo",
"mediaid": "[MediaID]" // required
}
}
Response
<?xml version="1.0"?>
<response>
<bitrate>[BitRate]</bitrate>
<duration>[DirationInSeconds]</duration>
<duration_timestamp>[DirationTimestamp]</duration_timestamp>
<duration_hms>[DirationHMS]</duration_hms>
<audio_bitrate>[BitRate]</audio_bitrate>
<video_codec>[Codec]</video_codec>
<video_bitrate>[BitRate]</video_bitrate>
<video_duration>[DirationInSeconds]</duration>
<video_duration_timestamp>[DirationTimestamp]</video_duration_timestamp>
<video_duration_hms>[DirationHMS]</video_duration_hms>
<frame_rate>[FrameRate]</frame_rate>
<size>[Size]</size>
<pixel_aspect_ratio>[AspectRatio]</pixel_aspect_ratio>
<display_aspect_ratio>[AspectRatio]</display_aspect_ratio>
<audio_codec>[Codec]</audio_codec>
<audio_bitrate>[BitRate]</audio_bitrate>
<audio_sample_rate>[SampleRate]</audio_sample_rate>
<audio_channels>[ChannelsNumber]</audio_channels>
<audio_duration>[DirationInSeconds]</audio_duration>
<audio_duration_timestamp>[DirationTimestamp]</audio_duration_timestamp>
<audio_duration_hms>[DirationHMS]</audio_duration_hms>
</response>
{
"response": {
"bitrate": "[BitRate]",
"duration": "[DirationInSeconds]",
"duration_timestamp": "[DirationTimestamp]",
"duration_hms": "[DirationHMS]",
"audio_bitrate": ["[BitRate]", "[BitRate]"],
"video_codec": "[Codec]",
"video_bitrate": "[BitRate]",
"video_duration": "[DirationInSeconds]",
"video_duration_timestamp": "[DirationTimestamp]",
"video_duration_hms": "[DirationHMS]",
"frame_rate": "[FrameRate]",
"size": "[Size]",
"pixel_aspect_ratio": "[AspectRatio]",
"display_aspect_ratio": "[AspectRatio]",
"audio_codec": "[Codec]",
"audio_sample_rate": "[SampleRate]",
"audio_channels": "[ChannelsNumber]",
"audio_duration": "[DirationInSeconds]",
"audio_duration_timestamp": "[DirationTimestamp]",
"audio_duration_hms": "[DirationHMS]"
}
}
Parameter | Description |
---|---|
bitrate | Total bitrate for the media file. |
duration | Tracks duration in seconds. |
pixel_aspect_ratio | Pixel's rectangle width/height ratio (1:1 = square pixel). |
display_aspect_ratio | Video frame's width/height ratio. |
audio_channels | Number of audio channels (commonly 1, 2 or 5.1). |
duration_timestamp | Tracks duration in HH:mm:ss:SSS format. |
duration_hms | Tracks duration in HHh mmmn sss SSSms format. |
video_duration | Video tracks duration in seconds |
audio_duration | Audio tracks duration in seconds |
video_duration_timestamp | Video tracks duration in HH:mm:ss:SSS format. |
audio_duration_timestamp | Audio tracks duration in HH:mm:ss:SSS format. |
video_duration_hms | Video tracks duration in HHh mmmn sss SSSms format. |
audio_duration_hms | Audio tracks duration in HHh mmmn sss SSSms format. |
Note
For each request, any parameters can be omitted.
Timestamp format notation
- HH – hours
- mm – minutes
- ss – seconds
- SSS – microseconds