Interface ILiveKitEgressService
Service for recording and streaming rooms, participants, or tracks.
Provides methods for starting and managing egress (recording/streaming) sessions. See LiveKit Egress API Documentation for more information.
public interface ILiveKitEgressService
Methods
ListEgressAsync(ListEgressRequest, CancellationToken)
Lists active and completed egresses.
Task<ListEgressResponse> ListEgressAsync(ListEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestListEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
StartParticipantEgressAsync(ParticipantEgressRequest, CancellationToken)
Starts a participant egress to record a single participant.
Task<EgressInfo> StartParticipantEgressAsync(ParticipantEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestParticipantEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
StartRoomCompositeEgressAsync(RoomCompositeEgressRequest, CancellationToken)
Starts a room composite egress (recording or streaming).
Task<EgressInfo> StartRoomCompositeEgressAsync(RoomCompositeEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestRoomCompositeEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
StartTrackCompositeEgressAsync(TrackCompositeEgressRequest, CancellationToken)
Starts a track composite egress to record specific tracks.
Task<EgressInfo> StartTrackCompositeEgressAsync(TrackCompositeEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestTrackCompositeEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
StartTrackEgressAsync(TrackEgressRequest, CancellationToken)
Starts a track egress to record a single track without transcoding.
Task<EgressInfo> StartTrackEgressAsync(TrackEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestTrackEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
StartWebEgressAsync(WebEgressRequest, CancellationToken)
Starts a web egress to record any website.
Task<EgressInfo> StartWebEgressAsync(WebEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestWebEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
StopEgressAsync(StopEgressRequest, CancellationToken)
Stops an active egress.
Task<EgressInfo> StopEgressAsync(StopEgressRequest request, CancellationToken cancellationToken = default)
Parameters
requestStopEgressRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
UpdateLayoutAsync(UpdateLayoutRequest, CancellationToken)
Updates the layout of a web composite egress.
Task<EgressInfo> UpdateLayoutAsync(UpdateLayoutRequest request, CancellationToken cancellationToken = default)
Parameters
requestUpdateLayoutRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.
UpdateStreamAsync(UpdateStreamRequest, CancellationToken)
Adds or removes stream endpoints for an active egress.
Task<EgressInfo> UpdateStreamAsync(UpdateStreamRequest request, CancellationToken cancellationToken = default)
Parameters
requestUpdateStreamRequestcancellationTokenCancellationToken
Returns
Exceptions
- LiveKitApiException
Thrown when the server returns a non-success HTTP status code.