The Enx.destroy() method allows the Moderator to conclude an ongoing session.

Method: Enx.destroy() – No Parameter required.

Callbacks:

  • ackDestroy – Acknowledgment to the Moderator when the session is destroyed.
  • roomDisconnected - Notification to all users in the Room when the session is destroyed.
Enx.destroy().  
ackDestroy:event=>{
    // Moderator is acknowledged that session is destroyed
              }
roomDisconnected:event=>{
     // Notification to all users in the Room when the session is destroyed.
              }

Error Codes & Exceptions

CodeDescription
5116Unauthorized Access. When a user with participant role invokes destroy().