GetMediaInfo

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]"
    }
}
ParameterDescription
bitrateTotal bitrate for the media file.
durationTracks duration in seconds.
pixel_aspect_ratioPixel's rectangle width/height ratio (1:1 = square pixel).
display_aspect_ratioVideo frame's width/height ratio.
audio_channelsNumber of audio channels (commonly 1, 2 or 5.1).
duration_timestampTracks duration in HH:mm:ss:SSS format.
duration_hmsTracks duration in HHh mmmn sss SSSms format.
video_durationVideo tracks duration in seconds
audio_durationAudio tracks duration in seconds
video_duration_timestampVideo tracks duration in HH:mm:ss:SSS format.
audio_duration_timestampAudio tracks duration in HH:mm:ss:SSS format.
video_duration_hmsVideo tracks duration in HHh mmmn sss SSSms format.
audio_duration_hmsAudio 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