Stay organized with collections
Save and categorize content based on your preferences.
We have created a Dialogflow CX custom event for Contact Center AI Platform (CCAI Platform)
that you can use with your Dialogflow CX agent's event
handlers. This is the wrapup custom event.
You can use custom events to handle things that happen outside of the
conversation with an end-user. Custom events are identified by name, and you can
configured them in your Dialogflow CX virtual agents using event handlers. For
more information, see Custom Events.
wrapup
This custom event indicates when an end-user leaves the session for any reason,
helping an agent react before the session closes.
For example, if a voice session with a Dialogflow CX virtual agent is
dropped due to customer desertion or call failure, CCAI Platform
transmits an event to Dialogflow CX. The wrapup custom event allows
the virtual agent to be configured to react to this event by running through a
specific wrap up flow, such as sending specific session data to an external API
endpoint.
The wrapup custom event only works with support agents.
It's doesn't work with virtual task assistants.
Best practices
The following are best practices to consider:
If you are using a Dialogflow CX virtual agent integrated with
CCAI Platform, you might see errors in your Dialogflow CX
application logs if no event handler is defined
for the wrapup event. To react to the wrapup custom event more broadly
than on a specific page in your agent, you can set up a flow-level event
handler.
When using the TurnSignals method
with Dialogflow CX, there could be issues with syncing the session
parameters from the reached_end_page conversation turn signal and the
transmission of the wrapup event by CCAI Platform that follows. To
handle this more gracefully, consider using the CCAI Platform custom
payload end conversation with your
Dialogflow CX agent instead of the End Session transition in your
flow. The End Session transition can then be configured on the event handler
for wrapup.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-29 UTC."],[],[],null,["# Virtual agent custom events\n\nWe have created a Dialogflow CX custom event for Contact Center AI Platform (CCAI Platform)\nthat you can use with your Dialogflow CX agent's [event\nhandlers](/dialogflow/cx/docs/concept/handler#event). This is the `wrapup` custom event.\n\nYou can use custom events to handle things that happen outside of the\nconversation with an end-user. Custom events are identified by name, and you can\nconfigured them in your Dialogflow CX virtual agents using event handlers. For\nmore information, see [Custom Events](/dialogflow/cx/docs/concept/handler#event-custom).\n\nwrapup\n------\n\nThis custom event indicates when an end-user leaves the session for any reason,\nhelping an agent react before the session closes.\n\nFor example, if a voice session with a Dialogflow CX virtual agent is\ndropped due to customer desertion or call failure, CCAI Platform\ntransmits an event to Dialogflow CX. The `wrapup` custom event allows\nthe virtual agent to be configured to react to this event by running through a\nspecific wrap up flow, such as sending specific session data to an external API\nendpoint.\n\nThe `wrapup` custom event only works with [support agents](/contact-center/ccai-platform/docs/virtual-agent).\nIt's doesn't work with virtual task assistants.\n\n### Best practices\n\nThe following are best practices to consider:\n\n- If you are using a Dialogflow CX virtual agent integrated with\n CCAI Platform, you might see errors in your Dialogflow CX\n application logs if no [event handler](/dialogflow/cx/docs/concept/handler#event-custom) is defined\n for the `wrapup` event. To react to the `wrapup` custom event more broadly\n than on a specific page in your agent, you can set up a [flow-level event\n handler](/dialogflow/cx/docs/concept/handler#event-flow).\n\n- When using the [TurnSignals](/dialogflow/cx/docs/reference/rpc/google.cloud.dialogflow.cx.v3beta1#turnsignals) method\n with Dialogflow CX, there could be issues with syncing the session\n parameters from the `reached_end_page` conversation turn signal and the\n transmission of the `wrapup` event by CCAI Platform that follows. To\n handle this more gracefully, consider using the CCAI Platform custom\n payload [end conversation](/contact-center/ccai-platform/docs/va-custom-payload#end_conversation) with your\n Dialogflow CX agent instead of the End Session transition in your\n flow. The End Session transition can then be configured on the event handler\n for `wrapup`."]]