is participant_disconnected event always emitted? ...
# ask-ai
b
is participant_disconnected event always emitted? Even when the call is disconnected by the user?
t
Thanks for reaching out, Harsh. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
The
participant_disconnected
event is always emitted when a participant leaves a room, regardless of how the disconnection occurs. This includes user-initiated actions (such as leaving the call), server-initiated operations, or network-related issues. The event is reliably triggered in all these scenarios, ensuring you can consistently handle participant cleanup or UI updates in your application. For more details on the disconnection scenarios and internal handling, refer to the SDK documentation and event handling guides in LiveKit. Sources: src/room/Room.ts | livekit-rtc/livekit/rtc/room.py | Handling events | LiveKit Docs | livekit-android-sdk/src/main/java/io/livekit/android/events/RoomEvent.kt | agent-console/lib/event-types.ts