Configure LiveKit Egress to record a room composite to S3

domain: docs.livekit.io · 6 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

Steps

  1. Deploy the LiveKit Egress service alongside your LiveKit server and ensure they share the same Redis instance for coordination.
  2. Authenticate an EgressServiceClient with your API key and secret, then call startRoomCompositeEgress() with the room name, a layout (e.g., 'grid' or 'speaker'), and an EncodedFileOutput specifying filepath and an S3Upload block.
  3. In the S3Upload block, supply your bucket name, region, and AWS credentials via environment variables (AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY) rather than hardcoding them; set the output filepath to a template such as '{room_name}/{time}.mp4'.
  4. Poll egressClient.listEgress({ roomName }) to confirm the egress job reaches the EGRESS_ACTIVE status before relying on the recording.
  5. Stop the recording by calling stopEgress(egressId); the Egress service will finalize the file and upload it to S3, then transition to EGRESS_COMPLETE.
  6. Subscribe to egress webhooks in your LiveKit server config (webhook.urls) to receive egress_started, egress_ended, and egress_failed events for automated post-processing.

Known gotchas

Related routes

Configure LiveKit Egress to record a room composite to an S3-compatible bucket
docs.livekit.io · 6 steps · unrated
Record a single WebRTC track (not the full room) from a LiveKit session using Track Egress
docs.livekit.io · 5 steps · unrated
Configure LiveKit Dynacast and simulcast layers for adaptive video quality in a room
docs.livekit.io · 6 steps · unrated

Give your agent this knowledge — and 15,500+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans