Set the Case Source to Chat when opening a case from a Chat Interaction
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-18-2023 01:51 PM
Hello
We've noticed in our testing that when an Agent is opening a case from a Chat Interaction, whether it be an HR case or ITSM Incident, the Case source defaults to Phone.
Is there a way to modify it so that 'only when' the case is opened from a Chat Interaction that the Case Source is set to Chat?
We want to avoid Agents forgetting to change the Case Source manually.
Thank you,
JY
1 REPLY 1

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-18-2023 03:09 PM
Hello @juisel,
- First, you need to create a scripted chat action that runs when the agent creates a case from a chat interaction. The scripted chat action should get the current interaction record and the created case record and set the case source field to “Chat”. You can use the GlideRecord object to query and update the records. You can also use the gs.addInfoMessage method to display a confirmation message to the agent.
- Second, you need to add the scripted chat action to the chat action menu of the agent workspace. The chat action menu is a list of actions that the agent can perform on a chat interaction, such as creating a case, transferring the chat, or ending the chat. You can configure the chat action menu by editing the sys_ui_ng_action table and adding your scripted chat action as a new record.
- Third, you need to test your scripted chat action by initiating a chat from the service portal and creating a case from the agent workspace. You should see that the case source field is automatically set to “Chat” and a confirmation message is displayed to the agent.
Hope this helps.
Kind Regards,
Swarnadeep Nandy