User Inactivity Detection and Handling¶
The Inactivity Detection and Handling feature detects user inactivity during handovers and enables automated responses, handover closures, or custom actions to optimize human agent efficiency.
Key Benefits¶
- Efficient Resource Use. Automatically frees human agents from inactive conversations.
- Improved User Experience. Sends timely prompts or closes stalled handovers smoothly.
Prerequisites¶
- A handover provider, for example, Cognigy Live Agent, is configured.
- The Endpoint that supports a selected handover provider is configured. For testing purposes, you can use the Webchat v3 Endpoint with Demo Webchat.
Restrictions¶
- This feature triggers Flows via inactivity timeouts only when the handover status is
queue
oractive
. User inputs won't trigger Flows after a handover begins, except for AI Copilot Flows.
How to Use¶
To use this feature, add Nodes to your Flow, then test your Flow via Demo Webchat and any handover providers, for example, Cognigy Live Agent.
How to Set Up¶
1. Add Handover to Agent Node
To ensure proper detection and handling of inactivity during queue time or active handovers, follow these steps:
- In the Flow editor, add the Handover to Agent Node.
- Open a Node editor by clicking the Handover to Agent Node, then go to the Event Settings section.
- Toggle on the Send Queue Event and Send Active Event settings:
- Send Queue Event — triggers an event when the user enters the queue. This option allows tracking inactivity while waiting for a human agent.
- Send Active Event — triggers an event when the human agent sends the first message. This option allows tracking inactivity during an active conversation.
- Save changes.
2. Configure Lookup Node
Set up the Lookup Node with handover statuses:
- In the Flow editor, below the Handover to Agent Node, add the Lookup Node.
- Open a Node editor by clicking the Node, then go to the Type setting, select Handover Status from the list. Save changes.
- Go to the child Nodes:
- Click the Case Node.
- In the Value field, specify the
active
handover status if you want to detect and handle inactivity while the end users are in the queue. Save changes.
- Click the second Case Node.
- In the Value field, specify the
queue
handover status if you want to detect and handle inactivity while the end users are in the queue. - Click Save Node.
- Click the Case Node.
- Add completed and error child Nodes by analogy.
3. Set Inactivity Time
If you want to detect inactivity during the queue time, the first timer should be started once the end user enters the queue.
To do this, add the Once Node to start the inactivity timer when you receive the queue event:
- Below the queue child Node, add Once Node.
- Below the On First Time child Node, add the Set Handover Inactivity Node.
- In the Set Handover Inactivity Node, specify the inactivity timeout in minutes, for example,
1
. On each incoming user input, the timer is automatically reset and starts from the beginning. Once the timer expires, an inactivity event is sent to the Flow. Save changes. -
Repeat the same steps for the active child Node in case you want to detect and handle inactivity during active handovers.
The timer is set in minutes and may vary by up to one minute. If there is no end user input, the timer will expire after the specified time. If an end user input is received before the timeout, the timer will automatically reset and start from the beginning.
4. Loop Back
Set the Go To Node to return to the Lookup Node. This moves the entrypoint to the Lookup Node, allowing the Flow to execute the correct Lookup child branch based on incoming events.
In the Go To Node editor, select Lookup from the Select Node list and Go To Node and wait for Input from the Execution Mode list in the Advanced section.
5. Handle Inactivity
An example of how detected inactivity could be handled is explained here:
- Add the If Node at the end of the Flow.
- In the Node editor, specify
input.handover.inactivityCount >= 2
. This allows handling the second detected inactivity differently from the first one. Note that theinput.handover.inactivityCount
is reset to 0 once the end user sends a message. - Below the If Node and its Else child Node, do the following to ask the end user, based on detected inactivity, if he is still there.
- Add the Say Node.
- In the Say Node editor, in the text field, specify
Are you still there? The conversation will be automatically closed soon
. - In Handover Settings > Handover Output Destination, select User to only show the message to the user and not the human agent. Save changes.
- Add the Set Handover Inactivity Node to start a subsequent inactivity timer.
If the inactivity count is greater than two, it triggers the close handover process, which can close the handover on both the user and human agent sides.
- Add the Say Node.
- Below the If Node and its Then child Node, do the following to auto-close the handover after the inactivity timer expired the second time in direct succession:
- Add the Close Handover Node to auto-close the handover.
- Add the Say Node.
- In the Say Node editor, in the text field, specify
You are back with the bot now!
. - In Handover Settings > Handover Output Destination, select User and Agent. Save changes.
If the inactivity count is less than two, it triggers prompt the user to respond to prevent the conversation from being automatically closed. The Set Handover Inactivity Node will set the time period for inactivity after which the conversation will be closed or restart a Flow from the beginning.
- Add the Close Handover Node to auto-close the handover.
6. Loop Back
Finally, add the Go To Node to return to the Lookup Node as you did before. In the Go To Node editor, select Lookup from the Select Node list and Go To Node and wait for Input from the Execution Mode list in the Advanced section.
How to Test¶
- Use Demo Webchat to initiate a handover.
- Wait past the set timeout, for example, 1 minute, without responding.
- Check for the
Are you still there?
message after the first timeout and handover closure after the second timeout.
Example¶
Imagine a user in a queue stops responding.
After 1 minute,
they see
Are you still there? The conversation will close soon
. If they remain inactive for another minute, the handover closes, and they get You’re back with the bot!
— freeing the human agent and keeping the chat flowing.