Logging Out with the JS SDK
This guide explains how to sign out of the TigerConnect platform using the JS SDK.
Signing Out
To stop receiving messages for a particular user and to cut off the connection with the server, be sure to sign out of the JS SDK.
While the platform does a good job of cleaning up open resources, it is always good housekeeping to sign out when the client does not want to show incoming messages.
See also client.signOutAllDevices() to sign the current user out of all of their devices.
Definition
client.signOut():Promise<void,Error>
Returns
An error will be thrown if the operation is unsuccessful, otherwise null
will be returned.
Examples
await client.signOut();console.log('Signed out successfully');
Signing Out of All Devices
Call this to completely sign out a particular user from all of their open TigerConnect sessions across all devices.
See also client.signOut() to sign out of the current device only.
Definition
client.signOutAllDevices():Promise<void,Error>
Returns
An error will be thrown if the operation is unsuccessful, otherwise null
will be returned.
Examples
await client.signOutAllDevices();console.log('Signed out successfully from all devices');