Recordings
The recordings resource captures a meeting five ways:
- the whole room, composed into one file;
- one participant;
- one track (audio, video, or screen);
- a server-side composite mix of selected participants;
- a two-channel stereo audio merge.
start and stop act on a room's live session. Room and composite start return an egress handle you pass to stop (a room recording can also stop by room id).
Room recordings
- Node.js
- Go
const rec = await client.recordings.start(roomId, {
composition: { layout: "grid", quality: "high" },
fileFormat: "mp4",
});
await client.recordings.stop(rec); // or client.recordings.stop(roomId)
rec, err := client.Recordings.Start(ctx, roomID, videosdk.RecordingStartParams{
Composition: &videosdk.Composition{Layout: videosdk.CompositionLayoutGrid, Quality: videosdk.Ptr(videosdk.CompositionQualityHigh)},
FileFormat: videosdk.RecordingFormatMP4,
})
client.Recordings.Stop(ctx, rec) // or videosdk.EgressHandle{RoomID: roomID}
start options: composition (see below), transcription, onFailure, fileFormat (mp4 or webm), webhookUrl, dirPath, resourceId, preSignedUrl.
Manage finished recordings:
- Node.js
- Go
await client.recordings.list({ roomId, withTranscription: true });
await client.recordings.get(recordingId, { withTranscription: true });
await client.recordings.delete(recordingId);
client.Recordings.List(ctx, videosdk.RecordingListParams{RoomID: videosdk.String(roomID), WithTranscription: videosdk.Bool(true)})
client.Recordings.Get(ctx, recordingID, videosdk.RecordingGetParams{WithTranscription: videosdk.Bool(true)})
client.Recordings.Delete(ctx, recordingID)
Participant recordings
- Node.js
- Go
await client.recordings.participant.start(roomId, { participantId, fileFormat: "webm" });
await client.recordings.participant.stop(roomId, participantId);
client.Recordings.Participant.Start(ctx, roomID, videosdk.ParticipantRecordingStartParams{ParticipantID: participantID, FileFormat: videosdk.ParticipantFormatWebM})
client.Recordings.Participant.Stop(ctx, roomID, participantID)
fileFormat is mp4, webm, or m3u8. Also list, get, and delete.
Track recordings
kind is required, and the kind you stop with must match the one you started.
- Node.js
- Go
await client.recordings.track.start(roomId, { participantId, kind: "video" });
await client.recordings.track.stop(roomId, participantId, "video");
client.Recordings.Track.Start(ctx, roomID, videosdk.TrackRecordingStartParams{ParticipantID: participantID, Kind: videosdk.TrackKindVideo})
client.Recordings.Track.Stop(ctx, roomID, participantID, videosdk.TrackKindVideo)
kind is audio, video, screen_audio, or screen_video. Also list, get, and delete.
Composite recordings
start returns a handle whose id is the recordingId you need to stop it.
- Node.js
- Go
const rec = await client.recordings.composite.start(roomId, {
participants: [{ participantId: "participant-alice", kind: ["audio", "video"] }],
watermarks: [{ type: "custom", imageUrl: "https://example.com/logo.png", text: "CONFIDENTIAL" }],
});
await client.recordings.composite.stop(rec);
rec, err := client.Recordings.Composite.Start(ctx, roomID, videosdk.CompositeRecordingStartParams{
Participants: []videosdk.CompositeParticipantSelector{
{ParticipantID: "participant-alice", Kind: []videosdk.TrackKind{videosdk.TrackKindAudio, videosdk.TrackKindVideo}},
},
Watermarks: []videosdk.CompositeWatermark{
{Type: "custom", ImageURL: "https://example.com/logo.png", Text: "CONFIDENTIAL"},
},
})
client.Recordings.Composite.Stop(ctx, rec)
Also list, get, and delete.
Merge recordings
- Node.js
- Go
const { recording } = await client.recordings.merge.create({
sessionId,
channel1: [{ participantId: "participant-alice" }],
channel2: [{ participantId: "participant-bob" }],
});
result, err := client.Recordings.Merge.Create(ctx, videosdk.MergeRecordingCreateParams{
SessionID: sessionID,
Channel1: []videosdk.MergeChannelEntry{{ParticipantID: "participant-alice"}},
Channel2: []videosdk.MergeChannelEntry{{ParticipantID: "participant-bob"}},
})
Also list and get.
Composition
The composition option controls layout and rendering; the same shape is used by HLS and RTMP. Set a named layout or a custom template URL.
| Field | Values |
|---|---|
layout | grid, spotlight, sidebar, or a custom template URL |
priority | SPEAKER or PIN |
gridSize | tiles in grid, 0–25 (default 25) |
orientation | portrait or landscape |
theme | DARK, LIGHT, or DEFAULT |
quality | low, med, high, or ultra |
There is no resolution option; use quality.
Got a Question? Ask us on discord

