Getting Started
Media Probe is a serverless media analysis function that inspects video files and streams and returns detailed metadata — codecs, tracks, frame rates, resolution, bitrate, and duration — in a single HTTP call. Built on FFprobe and packaged as a lightweight REST service, it is useful for validating media before transcoding, building QC pipelines, or auditing content libraries. Available as an open web service in Eyevinn Open Source Cloud.
Prerequisites
- If you have not already done so, sign up for an Eyevinn OSC account
Step 1: Create a Media Probe instance
Navigate to the Media Probe service in the Eyevinn OSC web console. Click Create function-probe and fill in:
| Field | Description |
|---|---|
| Name | Short alphanumeric name for your instance |
Click the instance card once the status turns green and running.
Step 2: Probe a media file or stream
Send a POST request to /api with a JSON body containing the medialocator field:
curl -X POST https://<your-instance-url>/api \
-H "Content-Type: application/json" \
-d '{"medialocator": "https://maitv-vod.lab.eyevinn.technology/VINN.mp4/master.m3u8"}'
The response contains a structured JSON object with full track metadata:
{
"streams": [
{
"index": 0,
"codec_name": "h264",
"codec_type": "video",
"width": 1920,
"height": 1080,
"r_frame_rate": "25/1",
"bit_rate": "4000000",
"duration": "120.00"
},
{
"index": 1,
"codec_name": "aac",
"codec_type": "audio",
"sample_rate": "48000",
"channels": 2
}
],
"format": {
"duration": "120.00",
"size": "60000000",
"bit_rate": "4000000",
"format_name": "mov,mp4,m4a,3gp,3g2,mj2"
}
}
The service also exposes interactive API documentation at https://<your-instance-url>/api/docs.
Step 3: Use in a pipeline
Media Probe works well as a pre-flight check before transcoding:
async function probeMedia(instanceUrl, mediaUrl) {
const response = await fetch(`${instanceUrl}/api`, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ medialocator: mediaUrl })
});
if (!response.ok) throw new Error(`Probe failed: ${response.status}`);
return response.json();
}
const metadata = await probeMedia(
'https://<your-instance-url>',
'https://example.com/video.mp4'
);
const videoTrack = metadata.streams.find(s => s.codec_type === 'video');
console.log(`Resolution: ${videoTrack.width}x${videoTrack.height}`);
console.log(`Codec: ${videoTrack.codec_name}`);
console.log(`Duration: ${metadata.format.duration}s`);
CLI usage
osc create eyevinn-function-probe myprobe