Overview
This service turns a public media address into a player frame. The frame lives on this domain. The original file or embed address is not written into the page.
You can make the frame in the Studio tab, or send the address to the getplayer endpoint and follow the redirect.
Studio
Open the Studio tab, paste one public http or https address, and create the link. The page then shows:
- A live preview of the player.
- The player URL, shaped like
https://ex.divhard.com/play/… - An iframe you can paste into your own page.
Each time you create a link, the token is new. Older links for the same media keep working.
getplayer endpoint
Send a GET request with the media address immediately after ?=. The response is a redirect to the player.
https://ex.divhard.com/getplayer?=https://vfaststream.co/e/S7vR0qIxTuZv6A browser, a link, or an iframe can use that address. The browser follows the redirect and opens the player. curl -I shows the Location header, which is the /play/… URL.
curl -I "https://ex.divhard.com/getplayer?=https://vfaststream.co/e/S7vR0qIxTuZv6"If the media address has its own query string, leave it in place. Everything after ?= is the media address, including &.
https://ex.divhard.com/getplayer?=https://example.com/watch?id=42&ref=homeThe same call also accepts ?url= instead of ?=. The value is still the rest of the query string.
https://ex.divhard.com/getplayer?url=https%3A%2F%2Fexample.com%2Fvideo.mp4Use a public http or https address. Local, private, and empty addresses are rejected.
Embed
Point an iframe at getplayer when you want the player to resolve the media address on each view.
<iframe
src="https://ex.divhard.com/getplayer?=https://vfaststream.co/e/S7vR0qIxTuZv6"
title="Player"
width="100%"
height="480"
style="border:0;max-width:100%;background:#000"
allow="autoplay; fullscreen; picture-in-picture; encrypted-media"
allowfullscreen>
</iframe>Or embed the finished /play/… URL from the Studio. That address does not change until you create a new one.
What you can play
A direct file is played as itself when the path ends with one of these extensions:
- MP4, M4V, MOV
- WebM
- Ogg and OGV
- MKV
- MPEG-TS
- M3U8 and M3U (HLS), including a master playlist with several qualities
- Audio: MP3, AAC, M4A, WAV, FLAC, and Ogg
Any other public page is treated as an embed. The player looks up the stream and plays it when a file or HLS playlist is found. A master playlist gets a quality menu. MPEG-DASH (.mpd) is not played.
https://ex.divhard.com/getplayer?=https://example.com/video.mp4
https://ex.divhard.com/getplayer?=https://example.com/master.m3u8Player controls
The frame fills its iframe. It has play and pause, a seek bar, volume, a live badge for live streams, and fullscreen. Picture in picture is available in browsers that support it.
- Quality appears when the stream has more than one level. The choice is remembered in the browser.
- Speed is 0.5× through 2×.
- Captions appear when the HLS stream includes them.
- Playback can resume near where it left off on the same browser.
Keyboard, when the frame is focused:
| Key | Action |
|---|---|
| Space or K | Play or pause |
| ← → | Seek |
| ↑ ↓ | Volume |
| M | Mute |
| F | Fullscreen |
| C | Captions, when a track exists |
| 0–9 | Jump to that tenth of the video |
Responses
| Status | Meaning |
|---|---|
| 302 | getplayer accepted the address. Location is the player URL. |
| 200 | The /play/… frame loaded. |
| 400 | The address is missing, not a public http(s) URL, or the host is not allowed. |
| 429 | Too many links were requested from this network. Wait and try again. |
A valid player frame can still fail later if the embed page has no playable stream, or if the file itself is gone. The frame then shows a retry button, which asks for a fresh stream.
JSON link
While the Studio on this site is available, GET or POST https://ex.divhard.com/api/encode.php with url returns the player URL and iframe without a redirect.
curl "https://ex.divhard.com/api/encode.php?url=https%3A%2F%2Fexample.com%2Fvideo.mp4"{
"ok": true,
"play": "https://ex.divhard.com/play/…",
"token": "…",
"iframe": "<iframe …>"
}A rejected address returns {"ok": false, "error": "…"} and status 400. Percent-encode url when you put it in a query string, because this call uses a normal url parameter.