Bot flow into Amazon Connect from Facebook Messenger

0

I have been using the QnA bot to answer simple questions in Facebook messenger. What i would like to add is when the customer asks for a human or agent, that the chat be transferred to an amazon connect chat agent.

(the above works great with the chat widget)

I was able to create a lambda function that calls the StartChatcontact api and I got the lambda function to work. However, That seems to be such a small piece of this puzzle. Support nor myself have not been able to find any good articles or documentation on what is really needed to have the bot hand off to connect from Facebook messenger. The only think i know is i have made the Facebook application primary (the bot connection). My understanding is that allows the bot permission to hand it over to connect.

So what is really needed and how can i make which sounds really simple to hand that chat off to a connect agent.

thanks Mike

1 Answer
-1

Integrating a Facebook Messenger bot with Amazon Connect for agent handoff is indeed a complex process that requires several components to work together. Here's an overview of what you need to accomplish this:

  1. Facebook Messenger Integration: You've already set up the QnA bot to handle simple questions in Facebook Messenger, which is a good start.

  2. Intent Recognition: Your bot needs to recognize when a customer is requesting a human agent. This could be through specific phrases or a button in the chat interface.

  3. Lambda Function: You've created a Lambda function that calls the StartChatContact API, which is a crucial step. This function will initiate the chat in Amazon Connect.

  4. Participant Creation: After starting the chat contact, you need to create a participant for the customer in the Amazon Connect chat. This is done using the CreateParticipant API.

  5. Message Streaming: Enable real-time streaming of chat messages between Facebook Messenger and Amazon Connect.

  6. Message Relay: Set up a system to relay messages between Facebook Messenger and Amazon Connect. This typically involves using webhooks from Facebook to receive messages and the SendMessage API to send messages to Amazon Connect.

  7. Contact Flow: Create a contact flow in Amazon Connect that can handle incoming chat requests and route them to available agents.

  8. Agent Workspace: Ensure that your Amazon Connect agents are set up to receive and respond to chat contacts in their agent workspace.

To implement this, you'll need to:

  1. Modify your bot to recognize when a customer requests an agent.
  2. When this occurs, use your Lambda function to start a chat contact in Amazon Connect.
  3. Create a participant for the customer in the Amazon Connect chat.
  4. Set up a system (likely another Lambda function) to relay messages between Facebook and Amazon Connect.
  5. Configure your Amazon Connect instance to handle incoming chat contacts and route them to agents.

The process is complex because it involves bridging two separate systems (Facebook Messenger and Amazon Connect) and ensuring that messages flow seamlessly between them. While the StartChatContact API is an important piece, it's just the beginning of the process.

Unfortunately, there isn't a straightforward, out-of-the-box solution for this specific integration. You may need to build a custom solution that ties these components together. Consider reaching out to AWS Professional Services or a partner with experience in this area if you need additional assistance in implementing this integration.
Sources
Integrate Amazon Connect chat into a mobile application - Amazon Connect
Integrate your AI-powered IVR/IVA for seamless customer interactions with Amazon Connect | AWS Contact Center
Customize chat flow experiences in Amazon Connect by integrating custom participants - Amazon Connect

profile picture
answered a month ago
  • That is the best explanation I have seen. Does not make me happy that it is that complicated but as the post pointed out i have a number of the steps completed. I will just tackle each step and then hopefully ask more question to link all the steps together and see if i can make this work. Fingers crossed.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions