Webex Contact Center – Connect to External Database via HTTP GET with Mock API

Overview

Webex Contact Center has the ability to easily connect to third party databases that are on the internet, parse the data, and store it as a variable in your flow. This can be useful for intelligent routing scenarios, customer experience improvements, and personalized touches. Some examples of how this data can be used:

  • Database stores customers Language and can be retrieved by a phone number lookup. This allows for routing to an agent that speaks the preferred language automatically.
  • Database stores customer records that are useful for agent interactions- such as previous engagements, additional contact details, and client name(s)

This process uses a mock database, that is not authenticated. See this article to add authentication for production use: Configure custom connector for Webex Contact Center

Customer Journey Data is another similar option that may be useful. As of the time of writing this article, the customer journey data is not as customizable as a third-party database, as it only allows specific data fields. If you only are looking to store and gather customer name, phone number, and recent interactions, and present to Agents – this may be worth looking into.


Prerequisites

To follow this guide, you will need the following:

  • Base knowledge of Webex Contact Center, including Flow Building
  • Admin access to the Webex Contact Center admin portal
  • A number for testing, that routes to Webex Contact Center
  • A free account with MockAPI
    • This is a free tool that can create a fake database very quickly, with parameters you can set. The database is accessible without authentication – so only used for demos or as a proof of concept.

Setup Mock API

Follow these steps to create a mock database with mockAPI. If you already have an account with a database populated, you may skip this section.

  1. After signing up for a free account, you must create a project in MockAPI
  • Once created, click into your project, and select new resource. This will allow you to customize the database schema (or the specific datapoints you are wanting – such as ID, or first name, language, etc.) Feel free to customize this for your own needs. The Left column indicates the datapoints name, the middle is the type of value, and the right is the format the data will be set to. The Faker.js indicates that mock API will populate fake data automatically, using the column on the right as a template.

For the purpose of this lab, we will be configuring the following fields for our data schema:

  • FirstName
  • LastName
  • Number
  • Language

There is no pre-populated option for Language. You can use ‘random.word’ as a placeholder, and manually edit the database after creation.

  • After creating the database, you will need to edit the number of entries by sliding the USER DATA field to the number of users you would like to populate data for.

Changing the user count will wipe your database’ data and re-populate it with entirely new fake data.

  • Edit the data by clicking Data. This will bring up a new window, with the pre-populated data. Edit fields as needed, for the demo to function properly. In the screenshot below, I have updated the first two entries only, from the default values.

Updating the phone number to you can make calls from, and adding a language field is required for the lab to function.


Setup Webex Contact Center Basics

Ensure you have the following items configured in Webex Contact Center before proceeding:

  • User(s) licensed as an agent.
  • Site
  • Teams and Queues
  • User Profile
  • Multimedia Profile
  • Channel
  • Inbound Dial Number

See the Cisco Admin Guide for details on how to configure each item: Webex Contact Center Setup and Administration Guide


Configure New Flow

Follow this section to create a call flow in Webex Contact Center.

You can also edit an existing flow if you would like to add this functionality to a pre-existing call flow.

  1. Within Webex Contact Center, navigate to the customer experience section → Flows. Create a new flow.
  • Name the flow, and click start building
  • If your call flow requires it, add the ‘Business Hours’ card to the flow, and connect it appropriately.

If you are using business hours, ensure you have the business hours set previously, in control hub before using the Business Hours card in the flow builder.

  • Add the Set Variable card to the flow, and connect to your working hours:
  • Click in the background/open space of the flow builder to access the Global Flow Properties. This is where we can create variables to be used by the flow. Navigate to the Flow Variables and select Add Flow Variable:
  • Create a variable called ANI, with the following values:

The purpose of this variable is to store the calling number in a specific format, to match the entries on the database. In this document, we will be taking the global variable “NewPhoneContact.ANI” that stores the calling number, and removing the leading +, as our mock API database does not include a leading +

  • Once the variable is created, click into your Set Variable card, and choose the newly created variable “ANI”. Set the value as: {{ NewPhoneContact.ANI | replace ({"+":""}) }}
  • Add the ‘HTTP Request” card to the flow and connect it to the Set Variable node. The HTTP Request will handle the API request to the database.
  • For the purpose of this article, we will not be authenticating to the database, as it is publicly accessible. With the HTTP Request card selected, disable Use Authenticated Endpoint. Set the Request URL to the URL from your mock API webpage.

You can get the full URL in Mock API by clicking the URL under “API Endpoint” from the MockAPI website.

  • On the HTTP request, Set the Method to Get. Create a Key that will use the ANI value to lookup the caller, based on their phone number. Set the Key = Number, with the value of {{ ANI }}. Select the Content Type to be Application/JSON.
  1. In the section below the Content Type of the HTTP Request, specify the database fields that you want to map as variables. Once these fields are mapped as variables, you can use the data for logic in call routing. For next steps to map variables, and use that for routing logic, or agent screen pops, see one of our use cases below: (COMING SOON)
    • Medical Companies: Automatically route callers to a queue where the agent speaks their language without requiring additional prompts. Screen pop customer data, such as email, doctor, medical record IDs, or other.
    • Law Firms: Gather information about the caller’s lawyer or legal case to direct them to the appropriate department, or any outstanding bills.

Reference

The below website provides additional instructions, and a video for, for utilizing this process. Please watch the video and ensure that all steps are being followed in the correct order.


Contact Us

If you have questions, would like to leave feedback, or want to discuss another topic, please contact us using one of the methods below. We look forward to speaking with you!

Phone: 314-888-2511

Email: [email protected] or [email protected]

Website: https://covene.com/contact-us/


Discover more from Covene

Subscribe to get the latest posts sent to your email.

Leave a Reply