1
API Call to Go Live
3+
Simultaneous Platforms
1080p
Max Resolution
Free
100 API Calls/mo

What You Will Build

By the end of this tutorial, you will have a browser-based application that captures your camera or screen, streams it simultaneously to YouTube Live, Twitch, and LinkedIn Live through V100's multicast infrastructure, displays real-time stream health metrics (bitrate, dropped frames, latency per platform), overlays live captions on the outgoing stream, and produces a VOD recording when you stop. The entire backend is handled by V100 — you write zero server code.

Multicast to YouTube + Twitch + LinkedIn
Browser-based capture (camera or screen)
Real-time health monitoring per platform
Live caption overlay on stream
Automatic VOD recording
Any custom RTMP destination
Multicast Architecture
Your Browser              V100 Ingest Server           Destinations
    |                          |                          |
    |--- MediaRecorder -------->|                          |
    |    (WebM chunks via POST) |                          |
    |                          |--- RTMP ---- YouTube ---->|
    |                          |--- RTMP ---- Twitch ----->|
    |                          |--- RTMP ---- LinkedIn --->|
    |                          |--- RTMP ---- Custom ----->|
    |                          |                          |
    |<--- health beacon --------|                          |
    |<--- transcription --------|                          |
    |                          |                          |
    |                     [VOD recording saved to S3]          |
            

Step 1 — Get Your Stream Keys

Before you start, you need RTMP stream keys from each platform. V100 uses these to push your video to each destination. Here is where to find them:

YouTube

  1. Go to YouTube Studio and click Go Live in the top right
  2. Select Stream tab (not Manage)
  3. Copy the Stream key and Stream URL (usually rtmp://a.rtmp.youtube.com/live2)

Twitch

  1. Go to Twitch Dashboard > Settings > Stream
  2. Click Show under Primary Stream Key and copy it
  3. The ingest URL is rtmp://live.twitch.tv/app (or your nearest ingest server)

LinkedIn

  1. On your LinkedIn feed, click Start a post > Go Live
  2. Select Custom Stream under streaming tools
  3. Copy the Stream URL and Stream Key

Keep stream keys secret. Treat RTMP stream keys like passwords. Anyone with your stream key can broadcast to your channel. Store them in environment variables or a secrets manager — never commit them to source control.

Step 2 — Create a V100 Live Session

The POST /api/live/start endpoint creates a live session and tells V100 where to multicast. You pass an array of platform configurations, each with the RTMP URL and stream key. V100 returns an ingestUrl where you send your video chunks and a sessionId to reference the stream.

Start a multicast live session
const API_KEY = process.env.V100_API_KEY; const startLiveSession = async () => { const session = await fetch('https://api.v100.ai/api/live/start', { method: 'POST', headers: { 'Authorization': `Bearer ${API_KEY}`, 'Content-Type': 'application/json', }, body: JSON.stringify({ title: 'My Multi-Platform Stream', resolution: '1080p', framerate: 30, bitrate: 4500, // kbps transcription: { enabled: true, language: 'en', burnCaptions: true, // burn captions into outgoing stream }, platforms: [ { name: 'youtube', rtmpUrl: 'rtmp://a.rtmp.youtube.com/live2', streamKey: process.env.YOUTUBE_STREAM_KEY, }, { name: 'twitch', rtmpUrl: 'rtmp://live.twitch.tv/app', streamKey: process.env.TWITCH_STREAM_KEY, }, { name: 'linkedin', rtmpUrl: process.env.LINKEDIN_RTMP_URL, streamKey: process.env.LINKEDIN_STREAM_KEY, }, ], }), }).then(r => r.json()); return session; // { // sessionId: "live_x7k9m2p4", // ingestUrl: "https://ingest.v100.ai/live/live_x7k9m2p4", // wsUrl: "wss://api.v100.ai/ws/live/live_x7k9m2p4", // status: "ready" // } };

V100 handles all RTMP multiplexing server-side. Your browser sends video to one endpoint; V100 fans it out to every platform. This means you use your upstream bandwidth once, not three times. The wsUrl gives you a WebSocket connection for real-time health monitoring and transcription events.

Step 3 — Capture and Send Video

With the live session created, capture video from the browser using getUserMedia (camera) or getDisplayMedia (screen), encode it with MediaRecorder, and send chunks to V100's ingest endpoint as they become available. This approach works in any modern browser without plugins.

Browser capture and upload
const startStreaming = async (session, source = 'camera') => { // Capture video source const stream = await ( source === 'screen' ? navigator.mediaDevices.getDisplayMedia({ video: { width: 1920, height: 1080, frameRate: 30 }, audio: true, }) : navigator.mediaDevices.getUserMedia({ video: { width: 1920, height: 1080, frameRate: 30 }, audio: { echoCancellation: true, noiseSuppression: true }, }) ); // Encode with MediaRecorder const recorder = new MediaRecorder(stream, { mimeType: 'video/webm;codecs=vp8,opus', videoBitsPerSecond: 4_500_000, }); // Send chunks every 1 second recorder.ondataavailable = async (event) => { if (event.data.size > 0) { await fetch(session.ingestUrl, { method: 'POST', headers: { 'Content-Type': 'video/webm', 'Authorization': `Bearer ${API_KEY}`, 'X-Session-Id': session.sessionId, }, body: event.data, }); } }; recorder.start(1000); // emit data every 1 second return { stream, recorder }; };

The MediaRecorder produces WebM chunks at one-second intervals. Each chunk is POSTed to V100's ingest server, which transcodes to H.264/AAC on the fly and pushes RTMP to each configured platform. The one-second interval balances latency (viewers see your stream with roughly 3-5 seconds of delay) against network efficiency (fewer HTTP requests than sub-second chunks).

Why not RTMP from the browser? Browsers do not support RTMP natively. The traditional approach requires OBS or a native application. V100's ingest endpoint accepts WebM over HTTPS, which works in any browser. V100 handles the RTMP conversion server-side. If you are building a native app, you can also push RTMP directly to rtmp://ingest.v100.ai/live/{sessionId}.

Step 4 — Monitor Stream Health

Once the stream is live, V100 sends real-time health telemetry over the WebSocket. This includes per-platform bitrate, dropped frames, latency, and connection state. Build a health dashboard to surface problems before your viewers notice them.

Stream health monitoring
const monitorHealth = (session, onUpdate) => { const ws = new WebSocket(session.wsUrl); ws.onmessage = (event) => { const msg = JSON.parse(event.data); if (msg.type === 'health') { // msg.platforms = [ // { // name: "youtube", // status: "live", // "live" | "reconnecting" | "failed" // bitrate: 4480, // actual kbps // droppedFrames: 2, // latencyMs: 1200, // uptime: 3600, // seconds // }, // { name: "twitch", status: "live", bitrate: 4510, ... }, // { name: "linkedin", status: "live", bitrate: 4490, ... }, // ] onUpdate(msg.platforms); } }; return ws; };

Health beacons arrive every 2 seconds. Each platform entry includes the current status (live, reconnecting, or failed), the actual bitrate being delivered, the droppedFrames count since the stream started, the round-trip latencyMs to the platform's ingest server, and total uptime in seconds. If a platform connection drops, V100 automatically reconnects with exponential backoff. You can display this data in a simple React component:

src/components/HealthDashboard.jsx
export function HealthDashboard({ platforms }) { return ( <div style={{ display: 'flex', gap: 12, flexWrap: 'wrap' }}> {platforms.map(p => ( <div key={p.name} style={{ padding: 16, borderRadius: 10, background: '#161616', border: `1px solid ${p.status === 'live' ? '#4ade80' : '#f87171'}`, minWidth: 200, }}> <div style={{ fontWeight: 700, textTransform: 'capitalize' }}> {p.name} <span style={{ marginLeft: 8, fontSize: 11, color: p.status === 'live' ? '#4ade80' : '#f87171', }}>{p.status}</span> </div> <div style={{ fontSize: 13, color: '#888', marginTop: 8 }}> Bitrate: {p.bitrate} kbps<br/> Dropped: {p.droppedFrames} frames<br/> Latency: {p.latencyMs}ms </div> </div> ))} </div> ); }

Step 5 — Add Live Captions

We enabled burnCaptions: true in Step 2, which tells V100 to overlay real-time captions directly into the outgoing video stream. Every viewer on every platform sees synchronized captions — no platform-specific caption integration needed. You also receive transcription events over the WebSocket so you can display them in your local UI.

Receive transcription events
// Inside the WebSocket onmessage handler: if (msg.type === 'transcription') { // msg = { // type: "transcription", // text: "Welcome to the stream everyone", // timestamp: 1711612800.45, // isFinal: true, // language: "en", // confidence: 0.97 // } if (msg.isFinal) { addCaptionToLog(msg.text); } else { updateInterimCaption(msg.text); } }

V100 sends both interim (partial) and final transcription results. Interim results update in real-time as the speaker talks, giving the audience a responsive captioning experience. Final results replace the interim text once the phrase is complete. The burned-in captions appear as a semi-transparent overlay at the bottom of the video frame, styled to match YouTube's built-in caption format.

Captions improve discoverability. YouTube indexes caption text for search. Streams with live captions rank higher in YouTube search results and reach hearing-impaired audiences. V100 supports 40+ languages for caption generation.

Step 6 — Stop and Get Recording

When you are done streaming, call POST /api/live/stop. V100 gracefully terminates RTMP connections to all platforms, finalizes the VOD recording, and returns the download URL. The recording includes burned-in captions if they were enabled.

Stop stream and retrieve VOD
const stopStream = async (sessionId) => { const result = await fetch( `https://api.v100.ai/api/live/${sessionId}/stop`, { method: 'POST', headers: { 'Authorization': `Bearer ${API_KEY}` }, } ).then(r => r.json()); return result; // { // sessionId: "live_x7k9m2p4", // duration: 3847, // seconds // recordingUrl: "https://storage.v100.ai/vod/live_x7k9m2p4.mp4", // transcriptUrl: "https://storage.v100.ai/transcripts/live_x7k9m2p4.json", // platforms: [ // { name: "youtube", totalDroppedFrames: 12, avgBitrate: 4485 }, // { name: "twitch", totalDroppedFrames: 5, avgBitrate: 4502 }, // { name: "linkedin", totalDroppedFrames: 8, avgBitrate: 4478 }, // ] // } };

The response includes a summary for each platform with total dropped frames and average bitrate over the session. The recordingUrl is a signed S3 URL that expires after 7 days — download it or transfer it to your own storage. The transcriptUrl provides the complete transcript in JSON format with timestamps, which you can use for blog posts, show notes, or SEO content.

On the client side, stop the MediaRecorder and release the camera or screen track after calling the API to ensure a clean shutdown:

Clean up browser resources
const cleanUp = (recorder, stream) => { recorder.stop(); stream.getTracks().forEach(t => t.stop()); };

V100 vs OBS + Restream + StreamYard

The traditional multi-platform streaming stack involves OBS for encoding, Restream or StreamYard for multicast, and manual caption setup per platform. Here is how that compares to V100's API-driven approach:

OBS + Restream StreamYard V100 API
Setup time 30–60 min per stream 10–15 min per stream One API call
Programmable No (GUI-only) No (GUI-only) Yes (full REST API)
Browser-based capture No (requires desktop app) Yes Yes
Live captions on stream Manual (OBS plugin) Limited Automatic (40+ languages)
Health monitoring API Not available Not available Real-time per-platform via WebSocket
VOD recording Local disk only Cloud Cloud (S3 URL)
Transcript Not included Not included Automatic (JSON + timestamps)
Embed in your app Not possible iframe only Full control (your UI)
Pricing $16–$49/mo (Restream Pro) $25–$65/mo Free tier, then usage-based
Custom RTMP destinations Yes Limited platforms Unlimited RTMP destinations

The critical difference is programmability. OBS and StreamYard are GUI tools for individual streamers. V100 is an API for developers building streaming into their products. If you are building a platform where users go live — an EdTech app, a virtual events platform, a gaming community — V100 lets you embed multi-platform streaming without asking users to install OBS or visit Restream.

Pricing

V100's free tier includes 100 API calls per month, which covers roughly 100 minutes of live streaming. That is enough for development and testing.

See the pricing page for full details.

Go Live on Every Platform Today

Get your free API key and start streaming to YouTube, Twitch, and LinkedIn with one API call. No OBS. No Restream. Just code.

Get Your Free API Key