Skip to content

Media extraction API for developers

Find the playable video or audio behind any URL. Microlink resolves the direct file, its dimensions, duration and type, so you can embed, transcribe or process it without scraping player markup.

The following examples show how to use the Microlink API with CLI, cURL, JavaScript, Python, Ruby, PHP & Golang, targeting 'https://vimeo.com/571394002' URL with 'video' API parameter:

CLI Microlink API example

microlink https://vimeo.com/571394002&video

cURL Microlink API example

curl -G "https://api.microlink.io" \
  -d "url=https://vimeo.com/571394002" \
  -d "video=true"

JavaScript Microlink API example

import mql from '@microlink/mql'

const { data } = await mql('https://vimeo.com/571394002', {
  video: true
})

Python Microlink API example

import requests

url = "https://api.microlink.io/"

querystring = {
    "url": "https://vimeo.com/571394002",
    "video": "true"
}

response = requests.get(url, params=querystring)

print(response.json())

Ruby Microlink API example

require 'uri'
require 'net/http'

base_url = "https://api.microlink.io/"

params = {
  url: "https://vimeo.com/571394002",
  video: "true"
}

uri = URI(base_url)
uri.query = URI.encode_www_form(params)

http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true

request = Net::HTTP::Get.new(uri)
response = http.request(request)

puts response.body

PHP Microlink API example

<?php

$baseUrl = "https://api.microlink.io/";

$params = [
    "url" => "https://vimeo.com/571394002",
    "video" => "true"
];

$query = http_build_query($params);
$url = $baseUrl . '?' . $query;

$curl = curl_init();

curl_setopt_array($curl, [
    CURLOPT_URL => $url,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_ENCODING => "",
    CURLOPT_MAXREDIRS => 10,
    CURLOPT_TIMEOUT => 30,
    CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
    CURLOPT_CUSTOMREQUEST => "GET"
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
    echo "cURL Error #: " . $err;
} else {
    echo $response;
}

Golang Microlink API example

package main

import (
    "fmt"
    "net/http"
    "net/url"
    "io"
)

func main() {
    baseURL := "https://api.microlink.io"

    u, err := url.Parse(baseURL)
    if err != nil {
        panic(err)
    }
    q := u.Query()
    q.Set("url", "https://vimeo.com/571394002")
    q.Set("video", "true")
    u.RawQuery = q.Encode()

    req, err := http.NewRequest("GET", u.String(), nil)
    if err != nil {
        panic(err)
    }

    client := &http.Client{}
    resp, err := client.Do(req)
    if err != nil {
        panic(err)
    }
    defer resp.Body.Close()

    body, err := io.ReadAll(resp.Body)
    if err != nil {
        panic(err)
    }

    fmt.Println(string(body))
}

Send the URL Get the media file back

2.20
secs
P95 video response
277
ms
P95 audio response
99.9
%
SLA Guaranteed

The file, not the player.

Every platform hides its media behind a different player, a different embed shape and a different set of scripts. Microlink resolves video and audio alike into one predictable response you can render, transcribe or process.

Direct file URL
The response carries a playable URL — video or audio — not an iframe or a player widget, so it goes straight to a media element, a pipeline or a storage bucket.
Dimensions and duration
Width, height, duration and media type come back with the URL, so you can lay out a player without a layout shift or a probe request.
Ready for transcription
Because you get the media rather than the page, audio drops directly into a speech-to-text pipeline with no intermediate scraping step.
Rendered before detection
Players that only mount after JavaScript runs are still found, because detection happens in a real browser after the page settles.
Pairs with metadata
Combine with metadata to get the title, description, artwork or poster image in the same call as the media file.

Start free, scale when ready

No signup, no API key, no credit card. The media extraction API is free to start — just call the endpoint.

Free

Try the API in seconds. No card.
$0/month
25 requests per day

Pro

For production workloads.
$49/month
$1.07 per 1,000 requests
46,000 requests / month
Cancel anytime · No setup fees

Enterprise

Dedicated infra for high-volume.
Custom
Tailored to your volume

Built on open source,
trusted by developers

The Microlink media pipeline is powered by battle-tested open source libraries used by thousands of developers worldwide. Our media extraction API is built on an open source foundation: explore the code, contribute, or run it yourself.

Every player is different. The file never is.

No player markup to reverse-engineer and no provider-specific integrations to maintain. Send a URL and get a playable file back via the video and audio APIs.

  • Direct File URLs

    The response carries a playable media URL rather than an iframe or a widget, so you can render it, stream it or queue it for processing.
  • Dimensions And Duration

    Width, height, duration and media type arrive with the URL, so players can be laid out without a probe request or a layout shift.
  • Transcription Ready

    You receive the media rather than the page hosting it, so audio drops straight into a speech-to-text pipeline with no scraping step.
  • Real Browser Detection

    Players that only mount after JavaScript runs are still found, because detection happens after the page has fully settled.
  • Metadata In The Same Call

    Request title, description, artwork and poster image alongside the media and pay for a single render instead of several.
  • Residential Proxy Resolution

    Route hard targets through residential IPs to get past Cloudflare, DataDome and Akamai without maintaining a proxy pool yourself.
  • Edge Cached Responses

    Configurable TTL from 1 minute to 31 days. Cache hits are free, return instantly, and never boot a browser.
  • Enterprise-Grade Reliability

    Production-ready infrastructure with a 99.9% uptime SLA and guaranteed performance for business-critical media workflows.
  • Generous Free Tier

    Start immediately with 25 requests/day. No setup fees, no credit card, and pay-as-you-grow pricing that scales with your usage.
  • Direct File URLs

    The response carries a playable media URL rather than an iframe or a widget, so you can render it, stream it or queue it for processing.
  • Dimensions And Duration

    Width, height, duration and media type arrive with the URL, so players can be laid out without a probe request or a layout shift.
  • Transcription Ready

    You receive the media rather than the page hosting it, so audio drops straight into a speech-to-text pipeline with no scraping step.
  • Real Browser Detection

    Players that only mount after JavaScript runs are still found, because detection happens after the page has fully settled.
  • Metadata In The Same Call

    Request title, description, artwork and poster image alongside the media and pay for a single render instead of several.
  • Residential Proxy Resolution

    Route hard targets through residential IPs to get past Cloudflare, DataDome and Akamai without maintaining a proxy pool yourself.
  • Edge Cached Responses

    Configurable TTL from 1 minute to 31 days. Cache hits are free, return instantly, and never boot a browser.
  • Enterprise-Grade Reliability

    Production-ready infrastructure with a 99.9% uptime SLA and guaranteed performance for business-critical media workflows.
  • Generous Free Tier

    Start immediately with 25 requests/day. No setup fees, no credit card, and pay-as-you-grow pricing that scales with your usage.

Start now

Get 25 requests/day with zero commitment. The media extraction API is free to use, with no account and no credit card. Send a URL and get a playable file back in seconds.
No login needed
25 reqs/day free
No credit card

Product Information

Everything you need to know about the Microlink media extraction API.

What does the API return for a video or an audio file?

A direct, playable file URL together with the media type and, when the source exposes them, the duration and — for video — the width and height. That is enough to render a player, queue a transcription job or archive the file without touching the original page.

Do I get an embed code or an actual file?

An actual file URL. That is the difference between this and an oEmbed style integration — you get media you can process, not markup you have to trust.
If you want embeddable player markup instead, embed returns a ready-to-drop iframe for the same URL.

Can I feed the result straight into a transcription service?

Yes. Because the response is the media file rather than the page that hosts it, it drops directly into a speech-to-text pipeline without an intermediate scraping or download step.

Does it work when the player loads via JavaScript?

Yes. Detection runs in a real browser after the page has settled, so players that only mount client-side are still found. A plain HTTP fetch would miss them entirely.

Can I get the title, artwork or poster image at the same time?

Yes. Request metadata alongside video or audio and a single call returns the title, description and imagery together with the media file, so you pay for one render instead of two.

What if a site blocks automated requests?

Enable proxy resolution to route through residential IPs. Antibot detection reports which provider blocked a request if one still does, so you know whether to retry or escalate.

Is every lookup billed?

No. Set a ttl and repeat lookups for the same URL inside that window are served from the edge cache instantly, at no cost and without booting a browser.