Skip to content
Fourohtwo

ton.halowerk.com/v1/hls-package

Encodes up to four renditions in one ffmpeg 6.1 pass (libx264 high profile, constrained VBR with maxrate 1.1x and buffer 2x the target, closed GOPs with a keyframe at every segment boundary) plus one AAC stereo audio rendition, and segments them as fragmented MP4 (CMAF) with the DASH muxer. The MPD comes from ffmpeg (SegmentTimeline; bandwidth replaced by the measured peak segment bit rate).

BaseAnswering
POSThttps://ton.halowerk.com/v1/hls-package

Uptime100% of 1 check in 30 days

30 days agoToday

Try it

Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.

The response shows up here.

Call it from an agent

// npm install fourohtwo
import { createPayer } from "fourohtwo";

// One agent key pays USDC on Base or USDG on Robinhood Chain, inside your spending rules.
const pay = createPayer({ privateKey: process.env.AGENT_KEY, maxPerCallUsd: "0.05" });
const res = await pay("https://ton.halowerk.com/v1/hls-package", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"renditions":[{"height":360,"video_kbps":700},{"height":240,"video_kbps":400}],"segment_s":2,"video_url":"https://upload.wikimedia.org/wikipedia/commons/2/2c/Rotating_earth_%28large%29.gif"}),
});
console.log(await res.json());

Example input

{
  "renditions": [
    {
      "height": 360,
      "video_kbps": 700
    },
    {
      "height": 240,
      "video_kbps": 400
    }
  ],
  "segment_s": 2,
  "video_url": "https://upload.wikimedia.org/wikipedia/commons/2/2c/Rotating_earth_%28large%29.gif"
}