Setting Up Google Dialogflow

This is an optional setup step if you are using ICC with Twilio and wish to leverage Google Dialogflow capabilities.

ICC uses Google Dialogflow Enterprise Edition for virtual agent and agent assist features. This page walks you through the manual steps of setting up Dialogflow to work with ICC.

Make sure you've already downloaded the ICC package and have extracted the import customization file and Dialogflow agent zip file. You'll need these files as you go through the following steps.

Prerequisites

ICC uses Google Dialogflow Enterprise Edition for virtual agent and agent assist features. Use of Dialogflow is optional for ICC, and can be turned off in the ICC App through the ICC_VAL_AI_FEATURE_TOGGLE constant, as described in more detail in the Setting Up the ICC Application section.

The following prerequisites apply if you are using ICC with Dialogflow:

  • Google Cloud Platform account.
  • An Appian service account will need a Google account to use virtual agent features.

Enable Virtual Agent and Agent Assist

By default all virtual agent and agent assist features are disabled. If you do not want to use Google Dialogflow to support virtual agent and agent assist you can skip the rest of this page.

To enable virtual agent and agent assist features, open the import customization file, uncomment the property value below ICC_VAL_AI_FEATURE_TOGGLE, and set the value to TRUE:

  • content._a-0000e10c-2ec1-8000-4b35-01ef9001ef90_29836.VALUE=TRUE

Create a New Google Project

This section should be completed by your IT/Admin team. The user performing these steps must have the ability to create a new Google project.

  1. Go to Google Cloud Platform (GCP) Console
  2. Create a new project, give it an appropriate name, organizational domain, and location
  3. Navigate to APIs & Services -> Library and enable the Dialogflow API
  4. Navigate to Credentials -> Create Credentials to create a new Service Account Key
    • Grant the Service Account the Dialogflow API Admin role
    • Ensure that they key type is set to JSON. Screen_Shot_2019-06-11_at_1.02.01_PM.png
  5. Open the import customization file
    • Uncomment the property value for ICC_VAL_AI_GCP_PROJECT_ID, and set the value to the new Google project ID (not the project number)
    • Update the following property values for the ICC AI DialogFlow API Credentials connected system to the values found in the Service Account Key file:
      • privateKeyId
      • privateKey
      • clientEmail
      • clientId

Create a Dialogflow Agent

This section should be completed by an ICC administrator. The user performing these steps must have Project Owner and Dialogflow API Admin privileges.

  1. Open the Dialogflow console
  2. Create a new Dialogflow agent and associate it with your Google project
  3. Upgrade to one of the Enterprise Edition versions to enable DialogFlow’s sentiment analysis
  4. Edit the agent
  5. Enable beta features and APIs (General tab)
  6. Enable Sentiment Analysis (Advanced tab) 2019-06-11_13-11-46_2.png
  7. Import the Dialogflow agent zip file using the Restore from Zip option (Export and Import tab)
  8. Save the agent

Please note that the import will have generated a new service account. This service account will not be used, and can be deleted if so desired. Only the service created in the above section will be used, as it has the right permissions.

The following steps are to work around a known bug with Dialogflow.

  1. Navigate to Intents -> Transfer -> Transfer Follow Up
  2. Turn off the setting for Set this intent as the end of conversation and save
  3. Turn on the setting for Set this intent as the end of conversation and save

Create a Dialogflow Phone Gateway

  1. Click Integrations on Dialogflow console
  2. Select Dialogflow Phone Gateway
  3. Go through the process to apply for a phone number
  4. Open the import customization file, uncomment the property value for ICC_VAL_AI_GOOGLE_GATEWAY_PHONE_NUMBER, and set the value to the new Dialogflow phone gateway number
    • This number should not include the +, country code, or any formatting

Please note that this phone number will only be used by the ICC Application to forward a call to Google for virtual agent capabilities. This phone number is not meant to be used directly.

Create a Dialogflow Knowledge Base

  1. Click Knowledge in the Dialogflow console
  2. Click Create Knowledge Base
  3. Enter a name and save
  4. Add FAQ resources to the knowledge base

That's it for now. You'll have to make a few more updates to the Dialogflow configuration in later steps.

Open in Github Built: Fri, Jun 03, 2022 (01:08:29 PM)

On This Page

FEEDBACK