Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

How to test Dialogflow CX VA transfer to Human Agent (chat feature)?

Hello, 

We seem to have connected dialogflow with ccaip (https://www.googlecloudcommunity.com/gc/Community-Blogs/How-to-integrate-Dialogflow-Virtual-Agent-wi...), however we're not sure how to test the chat feature?

We were expecting to use the dflow messenger integration to test and transfer the call and see a request open up on CCAI side but nothing pops up.

Solved Solved
0 4 1,233
1 ACCEPTED SOLUTION

We ended up going with a custom payload response (live agent handoff did not work) and utilizing the key menu_id, so that when the intent was triggered it would transfer to the correct queue mid conversation. The menu_id value could be found in the url of your specific queue that you've created for the queues in CCAIP.

Thank you so much for your help dawnberdan!

View solution in original post

4 REPLIES 4

Hi @syoonk32,

Welcome to Google Cloud Community!

You're on the right track! It sounds like you've successfully connected Dialogflow to CCAI (Contact Center AI), but you're hitting a snag when it comes to testing. Let's break down the testing process and troubleshoot why you might not be seeing requests in CCAI.

Testing Dialogflow-CCAI Integration

1. Dialogflow Messenger Integration: You're correct that the Dialogflow Messenger integration is a great way to test your agent's flow and interactions. However, it's not the primary way to test the integration with CCAI. The Messenger integration is designed for testing the agent's logic and responses within Dialogflow itself.

2. CCAI Testing: To test the Dialogflow-CCAI integration, you need to simulate a real call or chat interaction that would come through CCAI. Here are the common methods:

  • CCAI Simulator: CCAI provides a built-in simulator that allows you to test your agent's behavior in a simulated call or chat environment. This is the most straightforward way to test the integration.
  • CCAI Sandbox: If you have a CCAI sandbox environment, you can use it to test your agent with real calls or chats. This is a more realistic testing environment.

Testing Steps:

  • Configure CCAI: Ensure that your CCAI agent is properly configured to handle calls or chats and that the Dialogflow agent is correctly integrated.
  • Trigger a Call or Chat: Use the CCAI simulator, sandbox, or a third-party tool to initiate a call or chat.
  • Observe CCAI: Monitor the CCAI console or logs to see if the call or chat is being handled by your agent. You should see the request coming in and the agent's responses.

Troubleshooting:

  • Check CCAI Configuration: Verify that your CCAI agent is properly configured to handle calls or chats. Make sure the Dialogflow agent is correctly integrated and that the necessary permissions are in place.
  • Review Logs: Check the CCAI logs for any errors or warnings that might indicate a problem with the integration.
  • Test with a Simple Agent: If you're still having trouble, try testing with a very simple Dialogflow agent that just handles a few basic interactions. This can help isolate any issues related to the agent's logic.

In addition, The Dialogflow Messenger integration is great for testing your agent's logic, but you need to use CCAI's simulator, sandbox, or third-party tools to test the integration with CCAI. Make sure your CCAI agent is properly configured and that the Dialogflow agent is correctly integrated.

I hope the above information is helpful.

We managed to get testing going through the web sdk installation guide (https://cloud.google.com/contact-center/ccai-platform/docs/web-sdk).

We have been able to escalate with live agent handoff in our responses but unable to dictate which queue (have tried to use menuKey). Any suggestions on how to control which live agent queue it is transferred after the initial start of the conversation?

Thank you for your help.

Hi @syoonk32,

You're on the right track! The menuKey is used for routing within the virtual agent, not for directing the handoff to a specific live agent queue. Here's how you can control the queue during live agent handoff:

1. Use Custom Data:

  • Define Custom Data: In your Dialogflow CX agent, define a custom data field (e.g., targetQueue ) to store the desired queue name.
  • Set Custom Data: During the conversation flow, set the targetQueue custom data field based on the user's input or context.
  • Pass Custom Data: When triggering the live agent handoff, include the targetQueue custom data in the external_chat_transfer object.

2. Integrate with Contact Center AI Platform:

  • Contact Center AI Platform Integration: Ensure your Dialogflow CX agent is integrated with Contact Center AI Platform.
  • Queue Routing: Configure Contact Center AI Platform to route incoming handoffs based on the targetQueue custom data.

3. Use Webhooks:

  • Webhook Integration: Create a webhook that receives the targetQueue custom data from Dialogflow CX.
  • Dynamic Routing: Use the webhook to dynamically route the conversation to the appropriate queue in your contact center platform.

Important Considerations:

  • Contact Center Platform: Ensure your contact center platform supports custom data and routing based on that data.
  • Testing: Thoroughly test your implementation to ensure that conversations are routed correctly based on the targetQueue custom data.

I hope it helps! 

We ended up going with a custom payload response (live agent handoff did not work) and utilizing the key menu_id, so that when the intent was triggered it would transfer to the correct queue mid conversation. The menu_id value could be found in the url of your specific queue that you've created for the queues in CCAIP.

Thank you so much for your help dawnberdan!