Player Events: WebSocket Events
This event is emitted when the Discord voice WebSocket connection closes unexpectedly or intentionally.
It is useful for detecting disconnects, kicks, region changes, or bot mutes via server events.
These interfaces extendBaseEvent.
WebSocketClosedEvent
Emitted when the Discord voice WebSocket connection is closed for any reason.
Extends:BaseEvent.
Property Type Description Optional opstring = "event" Lavalink operation type. typestring = "WebSocketClosedEvent" Event type identifier. guildIdstring Guild this event applies to. codenumber WebSocket close code provided by Discord. reasonstring Reason string provided by Discord. byRemoteboolean Whether the closure was initiated remotely (by Discord).