Skip to content

Commit

Permalink
chore: update reset session (#461)
Browse files Browse the repository at this point in the history
  • Loading branch information
sojan-official committed Nov 1, 2023
1 parent 2fe82e1 commit e8e1937
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions docs/product/channels/live-chat/sdk/setup.md
Expand Up @@ -160,6 +160,12 @@ window.$chatwoot.setUser("<unique-identifier-key-of-the-user>", {

Make sure that you reset the session when the user logs out of your app.

### Reset the session (use this while you logout the user from your app)

```js
window.$chatwoot.reset();
```

### Identity validation using HMAC

To disallow impersonation and to keep the conversation with your customers private, we recommend setting up the identity validation in Chatwoot. Identity validation is enabled by generating an HMAC(hash based message authentication code) based on the `identifier` attribute, using SHA256. Along with the `identifier` you can pass `identifier_hash` also as shown below to make sure that the user is correct one.
Expand Down Expand Up @@ -251,12 +257,6 @@ window.$chatwoot.setLabel("support-ticket");
window.$chatwoot.removeLabel("support-ticket");
```

### Refresh the session (use this while you logout the user from your app)

```js
window.$chatwoot.reset();
```

### Widget errors

In order to see any errors in the widget, please make sure that you listen to `chatwoot:event` event as follows:
Expand Down

0 comments on commit e8e1937

Please sign in to comment.