Dialogflow App
    • Dark
      Light
    • PDF

    Dialogflow App

    • Dark
      Light
    • PDF

    Article summary

    Dialogflow lets you integrate lifelike conversational AI with advanced virtual agents into your websites, applications, messaging platforms, and contact centers. With the Rocket.Chat and Dialogflow integration, you can train your chatbot to handle specific queries and configure it to function as an Omnichannel agent.

    This document provides a guide to integrating Rocket.Chat with Dialogflow.

    You must have the Omnichannel feature enabled and have agents and managers assigned to receive and send Omnichannel messages.

    Install Dialogflow app

    To install the Dialogflow app,

    1. Go to Administration > Apps > Marketplace.

    2. Search for the Dialogflow app.

    3. Click Install and accept the needed permissions.

    See the official Dialogflow guide to learn how to set up Dialogflow. After creating a service account on your Google Cloud Console, download the JSON file containing the key and the necessary credentials.

    Bot user configuration

    To configure a bot user,

    1. Go to Administration > Workspace > Users.

    2. Create a new user (bot).

    3. Assign the roles Bot and Livechat Agent to this user.

    4. Configure the app to assign a “livechat-visitor” to this bot automatically. Navigate to Administration > Workspace >Settings > Omnichannel > Routing. Enable Assign new conversations to bot agent.

    Configure Dialogflow app

    1. On the Dialogflow App Info screen, go to Settings.

    2. Update the required fields:

      • Bot Username: Set the username of the bot you created earlier. This user will assist with the conversations through Dialogflow integration.

      • Project Id: The project_id property of the Google credentials file.

      • Environment: The environment where the bot is set up.

      • Client Email: The client_email property of the Google credentials file.

      • Private Key: The private_key property of the Google credentials file.

      • Language: Select the language in which you'd be interacting with the bot.

      • Fallback Responses Limit: If the Omnichannel end-user asks something the bot is not trained to answer and fails, this specifies the limit of the conversation failures before the conversation is forwarded to a human agent.

      • Target Department for Handover: Select the department to transfer customers when there is a “bot-to-live agent” handover.

      • Handover Message: A message sent to the customer upon handover.

      • Service Unavailable Message: A message sent by the bot to the customer if service is unavailable.

      • Close Chat Message: A message sent automatically to the customer when a chat is closed.

      • Hide Quick Replies: If enabled, all quick replies will hide when customers click on any of them.

    3. Click Save Changes.

    You can test your Dialogflow connection by:

    1. Viewing your app log. To view your app log:

      1. Click the kebab menu on the Dialogflow App Info screen and select View Logs.

      2. Select the recent app:getStatus tile. If Google Credentials Validation Success appears, your setup is ready. Otherwise, recheck your Dialogflow credentials.

    2. Navigating to the workspace’s Livechat and sending one of the prompts you’ve trained the bot to recognize. The Dialogflow bot is expected to reply with the appropriate response.

    Add quick replies support to your Dialogflow bot

    To add quick Replies, use Custom-Payload for responses on Dialogflow Console.

    1. Go to Intent > Responses > Add Responses > Custom Payload.

    2. Add the Quick Replies you want, following the structure format in the repository.

    Uninstall Dialogflow app

    To delete the app from your workspace,

    1. Go to Administration > Apps > Installed.

    2. Click the kebab menu against the Dialogflow app.

    3. Select Uninstall.

    4. Click Yes to confirm the uninstallation.


    Was this article helpful?

    ESC

    Eddy AI, facilitating knowledge discovery through conversational intelligence