Now in public beta — 5 free minutes, no card.
Real-time video AI API
Edit live video with a prompt.
Stream a camera in, get an AI-edited stream back in under a second. Restyle scenes, swap outfits, change backgrounds — live. Pay per second, no minimums.
Real-time video AI you can afford to put in production.
Priced for products, not demos: $25 / hour, billed per second.
Three calls to live video AI.
- 1
Create a session
One POST from your server with your API key and a prompt. You get a room and a token.
- 2
Join from the browser or app
Publish the camera with any LiveKit SDK. The edited video comes back into the same room.
- 3
Send a new prompt any time
One data message changes the edit while the video keeps running.
// 1. Your server: create a session
// Your server (Node). The API key never goes to the browser.
app.post("/start-edit", async (req, res) => {
const r = await fetch("https://babaganoush-production.up.railway.app/v1/sessions", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.VIDEO_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({ prompt: req.body.prompt }),
});
res.status(r.status).json(await r.json()); // livekit_url + client_livekit_token, no secrets
});
// 2. Your web page: join and send the camera
// Your web page. npm install livekit-client
import { Room, RoomEvent, Track, createLocalVideoTrack } from "livekit-client";
const session = await (await fetch("/start-edit", { method: "POST", /* prompt */ })).json();
const room = new Room();
room.on(RoomEvent.TrackSubscribed, (track) => {
if (track.kind === Track.Kind.Video) track.attach(document.querySelector("#edited"));
});
room.on(RoomEvent.DataReceived, (payload) => {
const msg = JSON.parse(new TextDecoder().decode(payload));
// {type: "status", state: "loading" | "streaming", ends_at} GPU starting / live, and when time is up
// {type: "error", message} something went wrong
// {type: "ended", reason} session over
});
await room.connect(session.livekit_url, session.client_livekit_token);
const camera = await createLocalVideoTrack({ resolution: { width: 848, height: 480, frameRate: 24 } });
await room.localParticipant.publishTrack(camera, {
source: Track.Source.Camera,
videoEncoding: { maxBitrate: 1_000_000, maxFramerate: 24 },
});
// 3. Change the prompt any time
const send = (text) => room.localParticipant.publishData(
new TextEncoder().encode(JSON.stringify({ prompt: text })), { reliable: true });
send("cyberpunk neon city");One price. Per second.
- ✓Billed per second. GPU start-up time is free.
- ✓Prepaid credits: $10 (24 min) · $25 (1 hour) · $100 (4 hours)
- ✓5 free minutes on sign-up, no card.
- ✓Credits never expire.
Need volume or a dedicated GPU? Contact us
Questions
What latency should I expect?
About 750 ms from camera to screen: the median of our test sessions, with the 95th percentile near 800 ms. The first session after a quiet period waits while a GPU starts. That wait is not billed, and you can call POST /v1/warm when a user opens your page to start a GPU early.
What resolution and frame rate?
848×480 at 24 frames per second, in and out.
Which browsers and devices work?
Video goes through LiveKit, so anything with a LiveKit SDK works: current Chrome, Edge, Firefox and Safari, and iOS, Android, Flutter, React Native and Unity apps. Your server only makes one HTTPS call to create a session.
How does billing work?
$25 / hour of streamed video (≈ $0.42 / minute), billed per second from prepaid credits. GPU start-up time is not billed. While a session is open we hold credit for its longest possible length (sessions run up to 2 minutes during the beta, so the hold is $0.83); when it ends you pay only for the seconds streamed. Credits never expire.
What happens to my video?
We don't record or store it. Frames travel through LiveKit Cloud to a GPU, are edited in memory and sent straight back. For billing we keep session records only: start and end time, length and the prompt text.
Is there a free tier?
Every new account gets 5 free minutes, no card needed. Free minutes share a daily capacity limit, so at busy times you may be asked to try again later or buy credits.