brash-lamp-29679
04/09/2026, 12:04 AMtall-airline-16756
04/09/2026, 12:04 AMtall-airline-16756
04/09/2026, 12:05 AMAudioTrackId for the track you want to egress (from Server API or webhooks).
2. Call the Egress service with a TrackCompositeEgressRequest, providing RoomName, AudioTrackId, and an Output set to a StreamOutput with Protocol: RTMP and the RTMP URL(s).
3. Start the egress; LiveKit will encode and stream the audio to the RTMP endpoint.
Example (Go):
info, err := egressClient.StartTrackCompositeEgress(ctx, &livekit.TrackCompositeEgressRequest{
RoomName: "my-room",
AudioTrackId: "audio-track-id",
Output: &livekit.TrackCompositeEgressRequest_Stream{
Stream: &livekit.StreamOutput{
Protocol: livekit.StreamProtocol_RTMP,
Urls: []string{"rtmp://live.twitch.tv/app/<stream-key>"},
},
},
})
Notes
• RTMP output is available only for Track Composite or Room Composite egress—not single Track Egress file exports.
• For audio-only streaming, omit VideoTrackId. Depending on transcoding, a black/placeholder video stream may be generated for RTMP sinks that require video.
If you want, tell me:
• Which server SDK you’re using (Go, Node.js, etc.),
• The RTMP provider (Twitch, YouTube, custom), and
• Whether you need audio-only or audio+placeholder video—
and I’ll give the exact request/code sample for your setup.
Sources: Universal Egress | LiveKit | server-sdk-js | livekit/livekit_composite | DeepWiki, with interactive elements