Start a conversational assistant on an open chat
Last Update: Oct 2024 • Est. Read Time: 6 MINConversational assistants are a powerful tool that promote customer self-service, boost agent productivity, and speed up response times.
On rare occasion, a chat customer might experience a network issue or reach out using an outdated link which could cause the conversational assistant to be skipped. In this article, we'll discuss how to set up a workflow automation that allows agents to apply a tag to a conversation to retroactively start an assistant. This will allow conversations under these circumstances to be given the same support experience as normal chat messages.
Who can access this feature? | |
User types | Admins and users with permissions to access workflows. |
In this article
Prerequisites
Before following this guide, you should already be comfortable with the basics of using workflows. Workflows overview
We also recommend being familiar with creating and using conversational assistants.
For this process, you must have already created the conversational assistant, which you will modify during this guide.
Copy the assistant ID
First, you'll use the Kustomer settings to find the conversational assistant's public ID.
To locate the assistant ID:
- Go to Settings and select Kustomer IQ > Conversational Assistants.
- Locate the desired assistant.
- Select to copy the assistant ID to your clipboard.
- Save the assistant public ID to a secure location so you can access it later in this guide.
Copy the tag ID
Next, you'll find the ID for the tag you want to use to trigger the workflow. Agents will add this tag to a conversation to start the assistant, so we recommend setting up a tag with an easily understood name like Launch Assistant.
To locate the tag ID:
- Go to Settings and select Workspace > Tags.
- Locate the desired tag and select Edit .
- Look at the URL in your browser's address bar. The tag ID is the alphanumeric code after
/tags/edit/
. - Copy the tag’s ID from the end of the URL, and save it to a secure location so you can access it later in this guide.
Create the workflow
Then, create the workflow using the provided template, which should set up most of the automation.
To create the workflow:
- Go to Settings and select Platform > Workflows.
- Select + Add Workflow.
- Select Custom Workflow.
- Fill out the Name and Description of this workflow. We always recommend as a best practice that you use clear and illustrative names and descriptions, so that it's easy to know what function this automation performs if another member of your team reviews this rule at a later date.
- Leave Callable Workflow off and then select Create.
- Open the Workflow Options menu in the toolbar and select Edit Workflow JSON.
- A modal appears where you can edit the code for this workflow. Select and delete all the current JSON code.
- Copy the code block below and paste it into the JSON text field in your Workflow Editor.
- Then, select Update to save the changes to the workflow and dismiss the JSON editor.
{ "description": "", "name": "launch-assistant", "steps": [ { "transitions": [], "errorCases": [], "id": "UN5BKgSYD", "action": "kustomer.assistant.launch", "params": { "publicId": "", "messageId": "/#steps.1.lastMessageIn.id", "conversationId": "/#steps.1.id" }, "appVersion": "kustomer-^1.9.2" }, { "transitions": [ { "target": "QEt_FXrHX", "condition": { "op": "and", "values": [ { "op": "eq", "values": [ "/#steps.1.lastMessageDirection", "in" ] }, { "op": "eq", "values": [ "/#steps.1.messageCount", "1" ] } ] }, "meta": { "name": "Initial-Inbound Message" } } ], "errorCases": [], "id": "LiLssS9QM" }, { "transitions": [ { "target": "UN5BKgSYD", "condition": { "op": "contains", "values": [ "/#steps.1.changes.attributes.tags.after", "" ] }, "meta": { "name": "Tag added" } } ], "errorCases": [], "id": "QEt_FXrHX" } ], "trigger": { "transitions": [ { "target": "LiLssS9QM", "condition": { "op": "contains", "values": [ "/#steps.1.channels", "chat" ] }, "meta": { "name": "Continue if chat" } } ], "eventName": "kustomer.conversation.update", "id": "1", "appVersion": "kustomer-^1.9.2" } }
Customize the workflow
As the last step, you will customize the workflow created from the JSON template.
To customize the workflow:
- In the conditional step Tag added, add the tag ID you found earlier as the condition value.
- In action step 4 Assistant Launch, add the assistant public ID you found earlier in the PublicId (string) field.
- Save your workflow and turn it on.
Agents will now be able to add the conversation tag Launch Assistant to any chat with no assistant containing 1 inbound message from a customer. This will launch the conversational assistant and allow the customer to go through the standard prompts in that assistant.