The classroom needs a clean end to its in-app notifications: revoke the issued tokens, disconnect remaining clients, then delete the channel. Keep that sequence in one application-owned shutdown operation. Consider a tabletop exercise in which the page says a classroom is still active after its scheduled end; the responder sees reconnect attempts, while the channel dashboard appears quiet. What page fired? Until that question has a precise answer, the dashboard is weak evidence.
Short answer: for a Node.js Express application, the end-session handler should revoke all issued tokens, disconnect remaining clients, then delete the channel, and record the session end time for attendance reporting. Deleting the channel first leaves clients retrying; revocation makes reconnect attempts fail authorization instead of recreating state.…