On conversation-stop
The On conversation-stop handler fires when a conversation session ends. Use it for cleanup, logging, or final data submissions.
The On conversation-stop handler fires when a conversation session ends. This can happen because the user closed the widget, the kiosk timed out due to defocus, or the session was explicitly ended by a flow. It is the right place to perform any cleanup, persist final data, or send a notification that the session is over.
When It Runs
This handler is triggered by the predefined conversation-stop signal, which fires when:
- The web widget is closed or the page is reloaded
- The kiosk loses focus (user walks away) and the session timeout triggers
- A
End Conversationnode runs in a flow - An Automation ends the conversation
The handler runs after the conversation has ended from the user's perspective – no more user messages are expected.
Common Uses
- Log session end – Send a webhook notification to your backend that the session is complete
- Save user data – Write any collected data to an external system (CRM, database) via
Call Webhook - Trigger a summary Automation – Use
Trigger Automationto kick off an end-of-session summary (though theEnd ConversationAutomation handles this automatically by default) - Clean up state – Reset conversation variables if needed for the next session
Typical Node Pattern
Signal Handler (On conversation-stop) ──► Call Webhook ──► Continue ProcessingOr simply:
Signal Handler (On conversation-stop) ──► Continue ProcessingAvailable Nodes
| Node | Category | Purpose |
|---|---|---|
| Continue Processing | Exit | Conclude the handler |
| Abandon Processing | Exit | Drop the event |
| Activate Flow | Exit | Trigger a Conversational Flow |
| Check Variable | Context | Read a variable value |
| Store Variable | Context | Write a variable |
| Find record(s) | Context | Query a data table |
| Route by Profile | Logic | Branch by touchpoint |
| Route by Language | Logic | Branch by active language |
| Route by Signal | Logic | Branch by signal |
| Is Flow Active | Logic | Check if a flow is currently active |
| Trigger Automation | Integration | Fire an Automation |
| Comment | Other | Canvas annotation |
Example: Webhook on Session End
Notify your backend when a conversation finishes, including the user's email if collected:
- Signal Handler (On conversation-stop)
- Check Variable (
{{variable.email}}) – branch: has value / empty - Branch A (has value) → Call Webhook (POST user data) → Continue Processing
- Branch B (empty) → Continue Processing
The On conversation-stop handler is a good complement to the End Conversation Automation. The Automation runs background tasks (summaries, titles), while this handler is better suited for immediate cleanup and notification tasks that should run synchronously at session end.
Kiosk-Specific Behavior
On kiosk deployments, On conversation-stop fires when the inactivity timeout triggers (the user walks away and the kiosk's defocus timer expires). This is a common trigger for resetting the kiosk to its idle state, which you can handle by activating a "reset" or "idle" flow.