Events enum

Defines all event types emitted by the VideoSDK.

  • The Events enum represents the complete list of events that can be emitted by the SDK during the lifecycle of a meeting, participant, media stream, or device interaction.

  • These events can be listened to using the on() method available on Room, Participant, or VideoSDK instances.


Usage

Events can be subscribed to using the on method:

room.on(Events.roomJoined, () {
  print('Room joined successfully');
});

Some events provide callback parameters:

room.on(Events.participantJoined, (participant) {
  print('Participant joined: ${participant.displayName}');
});

Notes

  • Event callback parameters vary depending on the event type.
  • Some events are room-level, while others are participant- or stream-level.
  • Certain events may only be available on specific platforms or SDK versions.
  • Deprecated events are retained for backward compatibility and may be removed in future releases.

Refer to the documentation of each individual event for details about parameters and usage.


Inheritance
Available extensions

Values

roomJoined → const Events

Emitted when the local participant successfully joins the room

Example

room.on(Events.roomJoined, () {
  print('Successfully joined the room!');
});
roomLeft → const Events

Emitted when the local participant leaves the room.

  • This event is triggered whenever the local participant exits the meeting, either voluntarily or due to an error or system action.

  • The event callback provides an optional LeaveReason parameter that describes why the participant left the room.

Event handler parameters

  • reason (LeaveReason?): Indicates the reason for leaving the room. Possible values include:

    • LeaveReason.websocketDisconnected Socket disconnected.

    • LeaveReason.removePeer Participant was removed from the meeting.

    • LeaveReason.removePeerViewerModeChanged Participant was removed because viewer mode was changed.

    • LeaveReason.removePeerMediaRelayStop Participant was removed because media relay was stopped.

    • LeaveReason.switchRoom Participant switched to a different room.

    • LeaveReason.roomClose The meeting has been closed.

    • LeaveReason.unknown Participant disconnected due to an unknown reason.

    • LeaveReason.removeAll All participants were removed from the meeting.

    • LeaveReason.meetingEndApi Meeting was ended using the Meeting End API.

    • LeaveReason.removePeerApi Participant was removed using the Remove Participant API.

    • LeaveReason.manualLeaveCalled Participant manually called the leave() method.

    • LeaveReason.websocketConnectionAttemptsExhausted Meeting left after multiple failed WebSocket connection attempts.

    • LeaveReason.joinRoomFailed Meeting left due to an error while joining the room.

    • LeaveReason.switchRoomFailed Meeting left due to an error while switching rooms.

Example

room.on(Events.roomLeft, (LeaveReason? reason) {
  if (reason != null) {
    print(
      'Left room due to ${reason.name} '
      '(code: ${reason.code}, message: ${reason.message})',
    );
  } else {
    print('Left room');
  }
});
roomStateChanged → const Events

Emitted whenever the room’s connection state changes.

  • This event is triggered on any change in the room’s lifecycle state, such as connecting, connected, disconnected, or reconnecting.

  • The current RoomState is passed as a callback parameter.

Event callback parameters

  • state (RoomState): Represents the current connection state of the room. Possible values:
    • RoomState.connecting
    • RoomState.connected
    • RoomState.disconnected
    • RoomState.reconnecting

Example

room.on(Events.roomStateChanged, (RoomState state) {
  switch (state) {
    case RoomState.connecting:
      print('Meeting is connecting');
      break;
    case RoomState.connected:
      print('Meeting is connected');
      break;
    case RoomState.disconnected:
      print('Meeting disconnected abruptly');
      break;
    case RoomState.reconnecting:
      print('Meeting is reconnecting');
      break;
  }
});
entryRequested → const Events

Emitted when a participant requests permission to join the room.

  • This event is triggered when a new participant attempts to join the room with the ask_join permission enabled in their token.

  • The event is emitted only to participants who have the allow_join permission in their token.

  • The event callback provides a Map<String, dynamic> containing the participant details along with allow() and deny() actions to either approve or reject the entry request.

Event callback parameters

  • data (Map<String, dynamic>): A map containing the following keys:

    • participantId (String): The unique ID of the participant requesting to join.

    • name (String): The display name of the participant requesting to join.

    • allow (Function): Call this function to approve the participant’s entry request.

    • deny (Function): Call this function to reject the participant’s entry request.

Example

room.on(Events.entryRequested, (Map<String, dynamic> data) {
  final String participantId = data['participantId'];
  final String name = data['name'];

  final Function allow = data['allow'];
  final Function deny = data['deny'];

  print('$name requested to join the room');

  // Allow the participant to join
  allow();

  // Or deny the participant's entry request
  // deny();
});
entryResponded → const Events

Emitted when a participant’s entry request receives a response.

  • This event is triggered after a join() request is either approved or denied.

The event is emitted to:

  • All participants who have the allow_join permission in their token
  • The participant who originally requested to join the room

Event callback parameters

  • participantId (String): The unique ID of the participant who requested to join the room.

  • decision (String): The decision taken on the entry request. Possible values are:

    • "allowed"
    • "denied"

Example

room.on(
  Events.entryResponded,
  (String participantId, String decision) {
    if (decision == 'allowed') {
      print('Entry request allowed for participant: $participantId');
    } else {
      print('Entry request denied for participant: $participantId');
    }
  },
);
micRequested → const Events

Emitted when a participant requests permission to enable the microphone of another participant.

  • This event is emitted to participant B when another participant A requests to enable participant B’s microphone.

  • If the request is accepted, the microphone of participant B will be enabled.

Event callback parameters

  • data (Map<String, dynamic>): A map containing the following keys:

    • accept (Function): Call this function to approve the microphone enable request.

    • reject (Function): Call this function to reject the microphone enable request.

Example

room.on(Events.micRequested, (Map<String, dynamic> data) {
  final Function accept = data['accept'];
  final Function reject = data['reject'];

  // Accept the microphone enable request
  accept();

  // Or reject the request
  // reject();
});
cameraRequested → const Events

Emitted when a participant requests permission to enable the camera of another participant.

  • This event is emitted to participant B when another participant A requests to enable participant B’s camera.

  • If the request is accepted, the camera of participant B will be enabled.

Event callback parameters

  • data (Map<String, dynamic>): A map containing the following keys:

    • accept (Function): Call this function to approve the camera enable request.

    • reject (Function): Call this function to reject the camera enable request.

Example

room.on(Events.cameraRequested, (Map<String, dynamic> data) {
  final Function accept = data['accept'];
  final Function reject = data['reject'];

  // Accept the camera enable request
  accept();

  // Or reject the request
  // reject();
});
participantJoined → const Events

Emitted when a new participant joins the room.

  • This event is triggered whenever a remote participant successfully joins the meeting. The newly joined participant is provided as a Participant object in the event callback.

Event callback parameters

  • participant (Participant): The participant who has joined the room.

Example

room.on(Events.participantJoined, (Participant participant) {
  print('Participant joined: ${participant.displayName}');
});
participantLeft → const Events

Emitted when a remote participant leaves the room.

  • This event is triggered whenever a participant who had joined the meeting exits the room, either voluntarily or due to an error or system action.

  • The event callback provides the participant’s ID along with a LeaveReason describing why the participant left.

Event callback parameters

  • participantId (String): The unique ID of the participant who left the room.

  • reason (LeaveReason): Indicates the reason why the participant left the room. Possible values include:

    • LeaveReason.websocketDisconnected
    • LeaveReason.removePeer
    • LeaveReason.removePeerViewerModeChanged
    • LeaveReason.removePeerMediaRelayStop
    • LeaveReason.switchRoom
    • LeaveReason.roomClose
    • LeaveReason.unknown
    • LeaveReason.removeAll
    • LeaveReason.meetingEndApi
    • LeaveReason.removePeerApi
    • LeaveReason.manualLeaveCalled
    • LeaveReason.websocketConnectionAttemptsExhausted
    • LeaveReason.joinRoomFailed
    • LeaveReason.switchRoomFailed

Example

room.on(
  Events.participantLeft,
  (String participantId, LeaveReason reason) {
    print(
      'Participant $participantId left the room '
      '(code: ${reason.code}, message: ${reason.message})',
    );
  },
);
pinStateChanged → const Events

Emitted when a participant’s pin state changes.

  • This event is triggered whenever a participant is pinned or unpinned in the room, either for camera, screen share, or both.

  • The event callback receives a Map<String, dynamic> containing details about the pin state change.

Event callback parameters

  • data (Map<String, dynamic>):
    • participantId (String): The ID of the participant whose pin state has changed.

    • state (Map<String, dynamic>): Represents the updated pin state. It contains boolean values for:

      • cam – Indicates whether the participant’s camera is pinned
      • share – Indicates whether the participant’s screen share is pinned
    • pinnedBy (String): The participant ID of the user who performed the pin or unpin action.

Example

room.on(Events.pinStateChanged, (Map<String, dynamic> data) {
  final String participantId = data['participantId'];
  final Map<String, dynamic> state = data['state'];
  final String pinnedBy = data['pinnedBy'];

  final bool camPinned = state['cam'] ?? false;
  final bool sharePinned = state['share'] ?? false;

  print(
    'Participant $participantId pin state changed '
    '(cam: $camPinned, share: $sharePinned) by $pinnedBy',
  );
});
participantModeChanged → const Events

Emitted when a participant’s mode changes.

  • This event is triggered whenever a participant switches their mode, such as moving between sending/receiving media, signaling-only, or receive-only mode.

Note: This event is supported in the Flutter SDK starting from version v1.3.0.

Event callback parameters

  • data (Map<String, dynamic>):
    • participantId (String): The ID of the participant whose mode has changed.
    • mode (String): The updated mode of the participant.

Example

room.on(Events.participantModeChanged, (Map<String, dynamic> data) {
  final String participantId = data['participantId'];
  final String mode = data['mode'];

  print('Participant $participantId changed mode to $mode');
});
speakerChanged → const Events

Emitted when the active speaker in the room changes.

  • This event is triggered whenever the currently active speaker changes. It can be used to track which participant is speaking at any given time.

  • If no participant is actively speaking, the callback parameter will be null.

Event callback parameters

  • activeSpeakerId (String?): The participant ID of the currently active speaker, or null if no participant is speaking.

Example

room.on(Events.speakerChanged, (String? activeSpeakerId) {
  if (activeSpeakerId != null) {
    print('Active speaker ID: $activeSpeakerId');
  } else {
    print('No active speaker');
  }
});
presenterChanged → const Events

Emitted when the active presenter (screen-sharing participant) changes.

  • This event is triggered when a participant starts or stops screen sharing. It provides the participant ID of the active presenter.

  • If screen sharing is stopped and no participant is presenting, the callback parameter will be null.

Event callback parameters

  • activePresenterId (String?): The participant ID of the active presenter, or null if no participant is currently sharing their screen.

Example

room.on(Events.presenterChanged, (String? activePresenterId) {
  if (activePresenterId != null) {
    print('Active presenter ID: $activePresenterId');
  } else {
    print('No active presenter');
  }
});
streamEnabled → const Events

Emitted when a media stream is enabled for a participant.

This event is triggered when a participant starts producing or consuming a media stream of any type, such as:

  • audio

  • video

  • screen share

  • The enabled Stream object is passed as the callback parameter.

Event callback parameters

  • stream (Stream): The media stream that has been enabled.

Example

room.participant.on(Events.streamEnabled, (Stream stream) {
  print('Stream enabled of kind: ${stream.kind}');
});
streamDisabled → const Events

Emitted when a media stream is disabled for a participant.

This event is triggered when a participant stops producing or consuming a media stream of any type, such as:

  • audio

  • video

  • screen share

  • The disabled Stream object is passed as the callback parameter.

Event callback parameters

  • stream (Stream): The media stream that has been disabled.

Example

room.participant.on(Events.streamDisabled, (Stream stream) {
  print('Stream disabled of kind: ${stream.kind}');
});
streamPaused → const Events

Emitted when a media stream is paused for a participant.

This event is triggered when a participant temporarily pauses producing or consuming a media stream of any type, including:

  • audio

  • video

  • screen share

  • The paused Stream object is passed as the callback parameter.

Event callback parameters

  • stream (Stream): The media stream that has been paused.

Example

room.participant.on(Events.streamPaused, (Stream stream) {
  print('Stream paused of kind: ${stream.kind}');
});
streamResumed → const Events

Emitted when a paused media stream is resumed for a participant.

-This event is triggered when a participant resumes producing or consuming a previously paused media stream of any type.

-The resumed Stream object is passed as the callback parameter.

Event callback parameters

  • stream (Stream): The media stream that has been resumed.

Example

room.participant.on(Events.streamResumed, (Stream stream) {
  print('Stream resumed of kind: ${stream.kind}');
});
streamStateChanged → const Events

Emitted when the state of a remote participant’s video or screen-share stream changes.

  • This event helps track stream health and lifecycle.

  • This event is emitted only for remote participants.

Callback Parameters

  • state (String)

    • "active" – Stream is working normally
    • "stuck" – Stream is not progressing
    • "freeze-detected" – Video freeze detected
    • "freeze-resolved" – Video freeze resolved
    • "ended" – Stream has ended
  • timestamp (int)

    • Time (in milliseconds since epoch) when the change occurred

Example

stream.on(Events.streamStateChanged, (state, timestamp) {
  print('Stream state: $state at $timestamp');
});
videoQualityChanged → const Events

Emitted when a participant’s video quality changes.

  • This event is triggered whenever the SDK automatically adjusts the video quality of a participant based on network conditions or adaptive subscription logic.

  • The callback receives a Map<String, dynamic> containing the previous and current video quality values.

Possible quality values

  • HIGH
  • MEDIUM
  • LOW

Event callback parameters

  • data (MapString, dynamic>):
    • currentQuality (String): The updated video quality.
    • prevQuality (String): The previous video quality.

Example

participant.on(Events.videoQualityChanged, (Map<String, dynamic> data) {
  final String currentQuality = data['currentQuality'];
  final String prevQuality = data['prevQuality'];

  print(
    'Video quality changed from $prevQuality to $currentQuality',
  );
});
qualityLimitation → const Events

Emitted when a quality limitation is detected or resolved during the meeting.

  • This event is triggered when the SDK applies or removes limitations on media quality due to factors such as network conditions or device performance.

Limitation types

  • congestion: Network congestion detected.
  • bandwidth: Insufficient available bandwidth.
  • cpu: High CPU usage on the device.

Limitation states

  • detected: A quality limitation has been detected.
  • resolved: The previously detected limitation has been resolved.

Event callback parameters

  • type (String): The type of quality limitation (congestion, bandwidth, or cpu).

  • state (String): The current state of the limitation (detected or resolved).

  • timestamp (int): The time (in milliseconds since epoch) when the event occurred.

Example

room.on(
  Events.qualityLimitation,
  (String type, String state, int timestamp) {
    print(
      'Quality limitation [$type] was $state at $timestamp',
    );
  },
);
recordingStarted → const Events

Emitted when room recording starts.

Deprecated:

  • This event will be deprecated in a future release.
  • Consider using the newer recording state or lifecycle events when available.

Example

room.on(Events.recordingStarted, () {
  print('Recording has started');
});
recordingStopped → const Events

Emitted when room recording stops.

Deprecated:

  • This event will be deprecated in a future release.
  • Consider using the newer recording state or lifecycle events when available.

Example

room.on(Events.recordingStopped, () {
  print('Recording has stopped');
});
recordingStateChanged → const Events

Emitted when the meeting’s recording state changes.

-This event is triggered whenever the recording lifecycle transitions between different states, such as starting, started, stopping, or stopped.

Possible recording states

  • RECORDING_STARTING: Recording is initializing and has not started yet.

  • RECORDING_STARTED: Recording has started successfully.

  • RECORDING_STOPPING: Recording is in the process of stopping.

  • RECORDING_STOPPED: Recording has stopped successfully.

Event callback parameters

  • status (String): The current recording state.

Example

room.on(Events.recordingStateChanged, (String status) {
  print('Meeting recording state: $status');
});
liveStreamStarted → const Events

Emitted when RTMP live streaming starts.

Deprecated:

Example

room.on(Events.liveStreamStarted, () {
  print('Live streaming has started');
});
liveStreamStopped → const Events

Emitted when RTMP live streaming stops.

Deprecated:

Example

room.on(Events.liveStreamStopped, () {
  print('Live streaming has stopped');
});
liveStreamStateChanged → const Events

Emitted when the meeting’s livestream state changes.

  • This event is triggered whenever the livestream lifecycle transitions between different states.

Possible livestream states

  • LIVESTREAM_STARTING: Livestream is initializing and has not started yet.

  • LIVESTREAM_STARTED: Livestream has started successfully.

  • LIVESTREAM_STOPPING: Livestream is in the process of stopping.

  • LIVESTREAM_STOPPED: Livestream has stopped successfully.

Event callback parameters

  • status (String): The current livestream state.

Example

room.on(Events.liveStreamStateChanged, (String status) {
  print('Meeting livestream state: $status');
});
hlsStarted → const Events

Emitted when HLS (HTTP Live Streaming) starts.

Deprecated:

  • This event will be deprecated in a future release.
  • Use Events.hlsStateChanged to track the full HLS lifecycle.

Event callback parameters

  • playbackHlsUrl (String)
  • livestreamUrl (String)

Example

room.on(
  Events.hlsStarted,
  (String playbackHlsUrl, String livestreamUrl) {
    print('HLS started');
    print('Playback URL: $playbackHlsUrl');
    print('Live URL: $livestreamUrl');
  },
);
hlsStopped → const Events

Emitted when HLS (HTTP Live Streaming) stops.

Deprecated:

Example

room.on(Events.hlsStopped, () {
  print('HLS streaming has stopped');
});
hlsStateChanged → const Events

Emitted when the meeting’s HLS (HTTP Live Streaming) state changes.

  • This event is triggered whenever the HLS lifecycle transitions between different states such as starting, playable, or stopped.

Possible HLS states

  • HLS_STARTING: HLS is initializing and has not started yet.

  • HLS_STARTED: HLS has started successfully.

  • HLS_PLAYABLE: HLS is live and playable. The callback will include playbackHlsUrl and livestreamUrl.

  • HLS_STOPPING: HLS is in the process of stopping.

  • HLS_STOPPED: HLS has stopped successfully.

Event callback parameters

  • data (Map<String, dynamic>):
    • status (String): Current HLS state.
    • playbackHlsUrl (String?): Available only when the state is HLS_PLAYABLE. This URL supports playback controls.
    • livestreamUrl (String?): Available only when the state is HLS_PLAYABLE. This URL provides a live stream without playback.

Note: downstreamUrl is deprecated. Use playbackHlsUrl or livestreamUrl instead.

Example

room.on(Events.hlsStateChanged, (Map<String, dynamic> data) {
  final String status = data['status'];

  print('Meeting HLS status: $status');

  if (status == 'HLS_PLAYABLE') {
    print('Playback URL: ${data['playbackHlsUrl']}');
    print('Live URL: ${data['livestreamUrl']}');
  }
});
transcriptionStateChanged → const Events

Emitted when the realtime transcription state changes.

  • This event is triggered whenever the lifecycle state of
  • realtime transcription is updated.

Possible transcription states

  • TRANSCRIPTION_STARTING: Realtime transcription is initializing and has not started yet.

  • TRANSCRIPTION_STARTED: Realtime transcription has started successfully.

  • TRANSCRIPTION_STOPPING: Realtime transcription is in the process of stopping.

  • TRANSCRIPTION_STOPPED: Realtime transcription has stopped successfully.

Event callback parameters

  • data (Map<String, dynamic>):
    • status (String): The current transcription state.
    • id (String): The unique ID of the transcription session.

Example

room.on(
  Events.transcriptionStateChanged,
  (Map<String, dynamic> data) {
    print(
      'Meeting transcription status: ${data['status']}',
    );
  },
);
transcriptionText → const Events

Emitted when realtime transcription text is received.

  • This event is triggered whenever new transcription text is generated during an active realtime transcription session.

  • The callback receives a TranscriptionText object containing details about the transcribed speech.

Event callback parameters

  • data (TranscriptionText):
    • participantId (String): ID of the participant whose speech was transcribed.
    • participantName (String): Display name of the participant.
    • text (String): Transcribed text.
    • timestamp (int): Time (in milliseconds since epoch) when the text was generated.
    • type (String): Type of transcription update.

Example

room.on(Events.transcriptionText, (TranscriptionText data) {
  print(
    'Transcription from ${data.participantName}: ${data.text}',
  );
});
error → const Events

Emitted when an error occurs in the room.

  • This event is triggered whenever the SDK encounters an error related to signaling, media handling, permissions, or internal processing during the meeting lifecycle.

Event callback parameters

  • error (Map<String, dynamic>):
    • code (int): Numeric error code identifying the error.
    • name (String): Short error name.
    • message (String): Human-readable description of the error.

Example

room.on(Events.error, (Map<String, dynamic> error) {
  print(
    'VIDEOSDK ERROR :: '
    '${error['code']} :: '
    '${error['name']} :: '
    '${error['message']}',
  );
});
deviceChanged → const Events

Emitted when available media devices change.

  • This event is triggered whenever a media device such as a camera, microphone, or speaker is connected to or removed from the system.

The callback receives the updated list of available devices.

Note:

  • This event is not supported on macOS applications.
  • Media permissions must be granted; otherwise, the device list may be empty or unavailable.

Event callback parameters

  • devices (List: The updated list of available media devices.

Example

VideoSDK.on(Events.deviceChanged, (List<DeviceInfo> devices) {
  print('Media devices changed: $devices');
});
characterJoined → const Events

@nodoc

characterLeft → const Events

@nodoc

characterMessage → const Events

@nodoc

userMessage → const Events

@nodoc

characterStateChanged → const Events

@nodoc

whiteboardStarted → const Events

Emitted when whiteboard sharing starts.

Example

room.on(Events.whiteboardStarted, () {
  print('Whiteboard sharing has started');
});
whiteboardStopped → const Events

Emitted when whiteboard sharing stops.

Example

room.on(Events.whiteboardStopped, () {
  print('Whiteboard sharing has stopped');
});
e2eeStateChanged → const Events

Emitted when the end-to-end encryption (E2EE) state changes for a participant’s media stream.

  • This event is triggered whenever encryption or decryption state updates occur for a specific media stream.

Event callback parameters

  • state (E2EEState): The current encryption or decryption state.

  • stream (Stream): The media stream associated with the encryption state change.

Possible E2EE states

  • EncryptionSucessed: Media encryption has been successfully applied.

  • DecryptionSucessed: Incoming media has been successfully decrypted.

  • EncryptionFailed: An error occurred while encrypting the media.

  • DecryptionFailed: An error occurred while decrypting the media.

  • InternalError: An internal encryption-related error occurred.

Example

widget.participant.on(
  Events.e2eeStateChanged,
  (E2EEState state, Stream stream) {
    print('$state is for the ${stream.kind}');
  },
);
pausedAllStreams → const Events

Emitted when all or specific media streams are paused.

  • This event is triggered after media streams within the meeting are successfully paused, either globally or for a specific type.

Event callback parameters

  • kind (String): Specifies which type of media stream was paused. Possible values:
    • audio – Audio streams were paused.
    • video – Video streams were paused.
    • share – Screen-sharing video streams were paused.

Example

room.on(Events.pausedAllStreams, (String kind) {
  print('Paused $kind streams');
});
resumedAllStreams → const Events

Emitted when all or specific media streams are resumed.

  • This event is triggered after paused media streams within the meeting are successfully resumed.

Event callback parameters

  • kind (String): Specifies which type of media stream was resumed. Possible values:
    • audio – Audio streams were resumed.
    • video – Video streams were resumed.
    • share – Screen-sharing video streams were resumed.

Example

room.on(Events.resumedAllStreams, (String kind) {
  print('Resumed $kind streams');
});
mediaRelayRequestReceived → const Events

Emitted when a media relay request is received in the destination meeting.

  • This event is triggered when a participant from another meeting requests to relay media streams into the current meeting.

Event callback parameters

  • meetingId (String): The ID of the source meeting from which the relay request was made.

  • peerId (String): The participant ID who requested the media relay.

  • displayName (String): Display name of the participant who requested the relay.

  • accept (Function): Call this function to accept the media relay request.

  • reject (Function): Call this function to reject the media relay request.

Example

room.on(
  Events.mediaRelayRequestReceived,
  (
    String meetingId,
    String peerId,
    String displayName,
    Function accept,
    Function reject,
  ) {
    print('Media relay request from $displayName');

    // Accept the relay request
    accept();

    // Or reject it
    // reject();
  },
);
mediaRelayStarted → const Events

Emitted when media relay to a destination meeting starts successfully.

Event callback parameters

  • meetingId (String): The destination meeting ID where media relay has started.

Example

room.on(Events.mediaRelayStarted, (String meetingId) {
  print('Media relay started for meeting: $meetingId');
});
mediaRelayStopped → const Events

Emitted when media relay to a destination meeting stops.

  • This event may be triggered due to user action, connection issues, or other termination reasons.

Event callback parameters

  • meetingId (String): The meeting ID where media relay was stopped.

  • reason (String): Reason for stopping the relay. Common values include:

    • user_stopped
    • connection_lost

Example

room.on(
  Events.mediaRelayStopped,
  (String meetingId, String reason) {
    print(
      'Media relay stopped for meeting $meetingId. '
      'Reason: $reason',
    );
  },
);
mediaRelayError → const Events

Emitted when an error occurs during media relay.

  • This event is triggered if the relay fails due to network issues, signaling errors, or internal failures.

Event callback parameters

  • meetingId (String): The meeting ID where the error occurred.

  • reason (String): Description of the error.

Example

room.on(
  Events.mediaRelayError,
  (String meetingId, String reason) {
    print(
      'Media relay error for meeting $meetingId: $reason',
    );
  },
);
mediaRelayRequestResponse → const Events

Emitted when a response to a media relay request is received in the source meeting.

  • This event notifies the requester whether their relay request was accepted or rejected.

Event callback parameters

  • decidedBy (String): The participant ID who responded to the relay request.

  • decision (String): The decision for the request. Possible values: accepted, rejected.

  • meetingId (String): The destination meeting ID for which the relay was requested.

Example

room.on(
  Events.mediaRelayRequestResponse,
  (String decidedBy, String decision, String meetingId) {
    print(
      'Media relay response by $decidedBy '
      'for meeting $meetingId: $decision',
    );
  },
);
translationStateChanged → const Events

@nodoc

translationText → const Events

@nodoc

translationLanguageChanged → const Events

@nodoc

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
name String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

values → const List<Events>
A constant List of the values in this enum, in order of their declaration.