CMS Development

GC5
Participant

Update authenticated user at re-login

Hi everyone, i am trying to integrate hubspot chat with javascript code, and i am having a problem.

 

Theese are may steps:

 

1. loading the chat with the method:

window.HubSpotConversations.widget.load() 

 

2. Passing email and token of the authenticated user in the settings: 

window.hsConversationsSettings = {
loadImmediately: false,
identification Email: myEmail,
identificationToken: myToken,
};

3. After a conversation, when the user logout I perform these cleaning operations:

window.HubSpotConversations.clear();
window.HubSpotConversations.widget.remove();

4. Now, if another user with different email and token login, the previous conversation remains and when the message is sent I find the previous user in the inbox.

 

Am I doing something wrong? how can I solve this problem?

 

Thanks,

GC5

0 Upvotes
2 Replies 2
kvonloesecke
Community Manager
Community Manager

Update authenticated user at re-login

Hi @GC5,

 

Thank you for reaching out to the Community!

 

I wanted to invite our subject matter experts to see if they have insight.

Hi @LMeert@Mike_Eastwood@himanshurauthan - Have you integrated javascript with HubSpot chat like @GC5 is describing?

Thank you!

 

Best,

Kristen


Did you know that the Community is available in other languages?
Join regional conversations by changing your language settings !
0 Upvotes
GC5
Participant

Update authenticated user at re-login

I am still waiting for a reply to this post.

0 Upvotes