- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā08-16-2020 11:57 PM
Hi Team,
We have successfully implemented Virtual chat and live agent config. One user reported an issue like his virtual agent chat gets stuck in live agent connection and unable to close the chat as 'End Conversation' button is disabled. The issue is still existing from past 1 week. Please helps us to resolve the issue.
Regards,
Saranya
Solved! Go to Solution.
- Labels:
-
Virtual Agent

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā08-17-2020 06:24 AM
HI saranyavs,
The reason could be the idle timer property. User could have routed to live agent and waited for time set in the idle timer property. After idle time has breached, the chat_queue_entry is fauled but the sys_cs_conversation is still live, which will never end. In these scenarios you have to make the conversation faulted to escapte out of the session.
Go the sys_cs_conversation and check for the chat which are in work in progress and change the state to faulted.
var tocheck = new GlideRecord('sys_cs_conversation');
tocheck.addEncodedQuery('state=chatInProgress');
tocheck.query();
while(tocheck.next()){
tocheck.state = 'faulted';
tocheck.update();
}
After this step is performed, when user logs in VA then it will greet with default msg.
Thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā08-17-2020 12:25 AM
Hi Please check this post https://community.servicenow.com/community?id=community_question&sys_id=dfe93b751b599090d01143f6fe4b...
Currently the end conversation is not linked to [switchTopic] method. It is only linked to topic discovery. so if you use anything apart from topic discovery then the button will be frozen.
you can try this instead of swtichTopic, remove the line completely and use this.
(function execute() {
vaVars.global_search_text = vaInputs.all_topics.getDisplayValue();
vaSystem.topicDiscovery();
})()
Please Mark as ā Correct if this solves your issue and also mark ???? Helpful if it helps resolve your problem.
Thanks,
Saji

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā08-17-2020 06:24 AM
HI saranyavs,
The reason could be the idle timer property. User could have routed to live agent and waited for time set in the idle timer property. After idle time has breached, the chat_queue_entry is fauled but the sys_cs_conversation is still live, which will never end. In these scenarios you have to make the conversation faulted to escapte out of the session.
Go the sys_cs_conversation and check for the chat which are in work in progress and change the state to faulted.
var tocheck = new GlideRecord('sys_cs_conversation');
tocheck.addEncodedQuery('state=chatInProgress');
tocheck.query();
while(tocheck.next()){
tocheck.state = 'faulted';
tocheck.update();
}
After this step is performed, when user logs in VA then it will greet with default msg.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā11-24-2020 12:36 AM
Thanks for this, encountered the same issue and perform this query as you've shared, I just use the sys_id.
var tocheck = new GlideRecord('sys_cs_conversation');
tocheck.addEncodedQuery('sys_id=7ea13703dba824106cc5285bd396195c');
tocheck.query();
while(tocheck.next()){
tocheck.state = 'faulted';
tocheck.update();
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā12-07-2020 05:31 AM
Hi Murali,
Where do we need to run the query?
I was not able to view the table name as "sys_cs_conversation".
Could you please suggest me.