Download as pdf or txt
Download as pdf or txt
You are on page 1of 93

Webex Contact Center APIs

Programmatic Contact Center & Developer Portal

Yaroslav Konstantin
Contact Center Business Unit UCCE TAC
March 2023
Agenda • API Fundamentals
API terminology

• All New Webex CC APIs


Reimagining the Contact Center where anything is possible

• Developer Portal, New features


Overview of developer portal, new features

• OAuth2
Understanding the access mechanism

• Use Cases
What is possible using these API’s, Live demo.

• Road Map, Sample & Support


What’s next and where to get help

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 2
00
API Fundamentals
Lightning Round – Acronyms!
Demystifying Terms
Representational State Transfer

RESTful
GET,POST,PUT,DELETE.
Going to a website is a REST GET call.
Signing up to a website is a POST call.
Editing the information provided during sign up is a PUT API call.
Deleting your profile from that website is a delete API call.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
HTTPS POST Event to your App

Webhooks

Asking someone to let you know when Bob


arrives. When Bob arrives, you get informed so
that you can greet Bob.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
Full Duplex HTTPS 1.1 Upgrade

Websockets

Is like either listening to the radio (one way) or


talking on the phone (two way), it is a
dedicated communication channel that is used
to stream data.
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
gRPC Remote Procedure Call

gRPC
Universal remote control that allows different
servers
to work like they are the same server
OR asking your teammate to do a task for you.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
HTTP 429 - Too Many Requests

Rate Limiting

Like a circuit breaker, it stops the flow of


requests to protect the system.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
Codes: Client 4xx Server 5xx

Client-Server

Think Customer << >> Provider


Client Requests
Server Responds

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
JavaScript Object Notation

JSON

Dictionary style list of lists – OR a moving box


that can have additional boxes inside which
contain other items.
Addressed like Truck.box[0].officesupply.pens.
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
Graph Query Language

GraphQL
Lets you “ask a question” = only receive the details that you
want.
Can configured to access more than a single object type
“AutoMagically ask the right people”.
It will only let you ask for information that it has.
--Your API CSM --

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Lightning Round – Acronyms!
Demystifying Terms
Open Authorization 2

OAuth2
Uses Tokens instead of passwords.
Like Airbnb - owner uses their “key” to create a door code.
You use that to access the property.
When the code expires, you no longer have access, and
you never touch the owner’s key!

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
API = Contract = Specification
Functionality. Backward Compatible. Constraints detailed.

Authentication
Community
Documentation Specification Authorization
& Support
Accounting

Schema Terms of Service Rate Limits Examples

Self—Service development. Build innovative solutions. Application extensions that Differentiate.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
01
Webex Contact Center APIs
New API Platform – Flexible & Extensible

• Customize every • Integrate into


step of the customer existing business
and agent journey applications and
tools

• Build new features • Track and improve


that extend the 15 KPIs
existing out-of-box
features

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 15
APIs Available today

Configuration

Reporting

Agent Webhooks

Call Control

Journey

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Configuration APIs
Address Book Global Variable
Agent Profile Multimedia Profile
Audio files Out dial ANI
Auxiliary codes Site
Queue Skill
Desktop layout Skill Profile
Dial Number Team
Dial plan User Profile
Entry point Work Types
Users

(Automated provisioning, Create/Read/Delete/Update


operations)

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Reporting API

• GraphQL/Search.
• Raw data access to analyzer.
• Get only what you want.
• ANI, Agent.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Webhooks
Subscribe to webhook in order to receive events

• Events from server to client


• One way, Opposite to APIs
• Subscribe

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Agent APIs

• WebSocket.
• Subscribe to WebSocket to get URL <-> start listening.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Call Control APIs

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Journey APIs

• Store/Retrieve customer data.

• Configure JDS Objects.

• Store journey events.

• Retrieve journey events (historic/Realtime).

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
02
Developer Portal
developer.webex-cx.com
Global, single, unified URL, New features
Try it out – on developer portal, defaults to the Region

API Root URLs – Ensure you’re using the right region’s URI

Region Developer Portal Region API Root URL

US,ANZ, UK, US https://api.wxcc-us1.cisco.com


https://developer.webex-cx.com/
EU
ANZ https://api.wxcc-anz1.cisco.com

UK https://api.wxcc-eu1.cisco.com

EU
https://api.wxcc-eu2.cisco.com
(Frankfurt)
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Start Here!
• Overview and general information
• Quick links for easy navigation
• Samples and Help
• API Reference

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Create Your App
• Building secure connection to your App

• One integration for multiple Apps

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
All You Need to Know to make an API Call
• What Endpoint does?
• Supported methods?
• Can we try it out? Yes we can!

Click Here!

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Sample Code and Try Out
• Syntax
• End Point path and query parameters
• Sample Code
• What Response to expect?
• Different variants of the request
• Response Codes

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Sample Code and Try Out
• Auto populated Access Token

• What token? Any ideas whose token is this?

• Auto populated Organization Id in Parameters

• Call API directly from Developer Portal!

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Sample Code and Try Out
• Response with the Code

• Convenient and Easy!

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Get Only What You Need

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Get Only What You Need
• Schema is subjected to changes
• Search supports
• tasks: corresponds to CSR Analyzer data

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Get Only What You Need
• Schema is subjected to changes
• Search supports
• tasks: corresponds to CSR Analyzer data
• taskDetails: corresponds to CAR Analyzer data

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Get Only What You Need
• Schema is subjected to changes
• Search supports
• tasks: corresponds to CSR Analyzer data
• taskDetails: corresponds to CAR Analyzer data

• agentSession: corresponds to ASR Analyzer data

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query....
• Searching a task

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query....
• Searching a task
• Providing time range

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query....
• Searching a task
• Providing time range
• Filter is optional

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query....
• Searching a task
• Providing time range
• Filter is optional
• Requested fields

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query....
• Searching a task
• Providing time range
• Filter is optional
• Requested fields
• Result

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Change log, New features

• Changes Portal is going through.


• NEW API being released
• CHANGES to existing API to avoid breakage.
• Information on GUIDES and DOC changes.
• GitHub SAMPLES

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Change log, New features
1) Install chrome extension

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Change log, New features

2) Go to https://developer.webex-cx.com/documentation/api-changelog

Click on RSS feed.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Change log, New features

3) New tab will open using chrome extension.


Click follow.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Change log, New features

4) Any updates on change log will be sent to your browser.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
03
Understanding OAuth2
Webex OAuth2 Mechanism – Overview

• Create an integration to obtain clientid and


client secret.

• Once you obtain an Org’s access_token and


refresh_token, you can access their data.

• Use the refresh_token before expiry (12


hours) to get another access_token

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
• User Profiles and Scopes
Webex Common apply.
Identity • You need a Contact Center
(Login with Webex) Administrator Role to Read
and Write to all endpoints.

Your
Application Webex Contact Center APIs
api.wxcc-eu2.cisco.com/v1/tasks
1 api.wxcc-eu2.cisco.com/v1/captures
Create integration
The User first Reaches Your App api.wxcc-eu2.cisco.com/v1/search
https://your-app.com

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
Your App then redirects the user to Webex
Webex Common With the Client ID, Scopes needed
2 Identity
(Login with Webex) config config_read config_write

Your
Application Webex Contact Center APIs
api.wxcc-eu2.cisco.com/v1/tasks
1 api.wxcc-eu2.cisco.com/v1/captures
api.wxcc-eu2.cisco.com/v1/search

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
User is Greeted
Webex Common
Identity with the “Webex Login” Screen
(Login with Webex)
Signs in!
Your 3
Application Webex Contact Center APIs
api.wxcc-eu2.cisco.com/v1/tasks
api.wxcc-eu2.cisco.com/v1/captures
api.wxcc-eu2.cisco.com/v1/search

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
Webex Common
Identity
(Login with Webex)

Your 4
Application Webex Contact Center APIs
Webex Redirects api.wxcc-eu2.cisco.com/v1/tasks
back to the “Redirect URI” api.wxcc-eu2.cisco.com/v1/captures
of your App with the api.wxcc-eu2.cisco.com/v1/search
”Authorization Code”

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
Webex Common
5 Identity
(Login with Webex)
access_token

Your Your App reaches out to


Application Webex to Request an
Webex Contact Center APIs
Access Token
api.wxcc-eu2.cisco.com/v1/tasks
api.wxcc-eu2.cisco.com/v1/captures
api.wxcc-eu2.cisco.com/v1/search

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
Webex Common
Identity
(Login with Webex)

Your 6
Application Webex Contact Center APIs
api.wxcc-eu2.cisco.com/v1/tasks
api.wxcc-eu2.cisco.com/v1/captures
Your App uses the access_token api.wxcc-eu2.cisco.com/v1/search
to access the Webex CC APIs

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
Webex Common
Identity
(Login with Webex)

Your
6
Application Webex Contact Center APIs
api.wxcc-eu2.cisco.com/v1/tasks
api.wxcc-eu2.cisco.com/v1/captures
7 api.wxcc-eu2.cisco.com/v1/search
Data is returned to the App,
as long as the access_token is valid

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
OAuth2 Access Token Flow
Before the refresh_token expires,
Webex Common the app can continue to ask
Identity for access_tokens in the background.
(Login with Webex)

Your … Data ..
Application Webex Contact Center APIs
api.wxcc-eu2.cisco.com/v1/tasks
api.wxcc-eu2.cisco.com/v1/captures
8 api.wxcc-eu2.cisco.com/v1/search
The user enjoys the additional capabilities
provided by your Application

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
04
Use Cases
Handling an Emergency situation

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – Handling an Emergency situation.
Consider a scenario where a supervisor needs ability to change routing decision during
an emergency without accessing admin portal.

Start Flow Main IVR Menu Queue

Emergency IVR

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – Handling an Emergency situation.
Consider a scenario where a supervisor needs ability to change routing decision during
an emergency without accessing admin portal.

Condition

Start Flow GV = False Main IVR Menu Queue

GV = True

Emergency IVR

• How it can be done with API help?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – Handling an Emergency situation
Webex Contact Center

Flow
Start Flow

Entry Point
1 2 3

Collect
Digits 2 Condition HTTP Request

Supervisor
Global Variable
Toggle

Webex CC
API

4
Webex
Connect

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Step 1: Map a flow to EP

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Step 2: Authorize the request

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Step 3: Invoke Webex Connect Webhook

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Step 4: Update Webex Contact Centre Configuration

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Callback from website

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 64
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – Callback from website, how ?
1) Client: The website where the user is making the request from.
Client
2) POST request from client to backend server.
(Can see request data in browser console)
3) Backend server - To receive the POST request.

4) Backend server - Call Webex cc task callback API to initiate callback request.
Wait for response code and continue accordingly.
Backend Server

Name, Email, Callback Reason Attributes


API server

Phone Number Destination

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Preferred agent callback

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 67
Use case – Preferred agent callback, how?
• Request from a website
• Programmatically pull agents
• Initiate a POST request to task
API with outboundType as ‘EXECUTE_FLOW’ in re
quest Body and EP ID of the inbound entry point to
trigger QtoAgent Flow.
•• Flow with preferred agent routing and a
flow variable that will receive agent email ID.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Fully Custom agent
desktop

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 69
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – Fully custom Agent desktop app
• Create a custom desktop mobile application.

• Agent and call control API’s

REST
Client Server

WebSocket
Server Client

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Wallboard

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 72
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – WallBoard
• Showcase data which is not present on stock dashboard.
• Another example: Pull abandoned calls in last 2 minutes.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Use case – WallBoard
• Making a backend API calls every X seconds from browser.
• Design the query depending upon the data you would like to see on wallboard.
• Token management to rotate access token every 10 hours.
• POST API call to API GW (authorization, rate limiting)
• Call to Backend service group.

Browser(Client)
API GW DB
/activeCalls:4000
Backend server

• GraphQL query
• Token management

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query…..?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query…..?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query…..?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query…..?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Query…..?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Response…..?

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
05
Availability & Roadmap

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 82
Developer Experience Roadmap (Jan’23)

Available Today Coming Soon


• Detailed API reference, guides and getting started Developer Portal
documents • Organize API by use cases
• API flavors supported – REST, gRPC, GraphQL, • Marketplace – Apphub
Webhook events
• Sandbox
• SDKs (Desktop JS SDK)
• Search functionality
• Sample code and API calls in 6 variants (cURL,
JavaScript, Java, C#, Python, Go)
• Embedded interactive editor & try it out. Contact Center APIs
• Changelog and Subscription • Flow Import/Export APIs
• Partner Showcase • Bulk Data Export APIs
• Support (FAQs, Developer Community) • Outbound Dialer APIs
• Github Sample code & Demos • Supervisor Desktop APIs

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
06
Samples & Support

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 84
API Use case Samples Available on GitHub
• GitHub Repo – CiscoDevNet
webex-contact-center-api-samples
• Sample Code - Clone
• ReadMe – Environment.
• Video Tutorials - Use Cases, API, code

https://github.com/
CiscoDevNet/
webex-contact-center-api-samples

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
API Use case Samples Available on GitHub
• Checkout out the GitHub – CiscoDevNet
repository:
webex-contact-center-api-samples
• Sample Code
• ReadMe
• Video Tutorials
• Use Cases

https://github.com/
CiscoDevNet/
webex-contact-center-api-
samples

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Support

• Break fix.
• API working and no longer works.
• Provide tracking ID from dev portal.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Webex Contact Center APIs Support Community
Cisco Community > Technology and Support > Developer Hub > Developer Collaboration > Contact Center

• Consulting, Support community


• Various discussions available already
© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Webex Contact Center APIs Support
For anything related to API specific Q&A and support open a ticket
using the following method:

Email: wxccdevsupport@webex.com
OR
Form: https://devsupport.webex.com/hc/en-us/requests/newchoose

*The above form will show up soon inside our dev portal

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Sandbox, Coming soon

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential
Takeaways
• Go to developer.webex-cx.com
• Login with a WebexCC Admin
• Try out the APIs live & use the
access_token for 12 hours -> In
a Demo!
• Check out the samples on
GitHub
• Participate in the Cisco
Developer Community
• Try out lab.

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 91
References
• Developer Portal: https://developer.webex- Portal
cx.com/ https://developer.webex-cx.com/

external
• Desktop SDK: https://developer.webex-
cx.com/documentation/guides/desktop
Support Mailer
• Partner Community:
https://community.cisco.com/t5/contact- wxccdevsupport@webex.com
Guidance – Use Developer Community
center/bd-p/j-disc-dev-contact-center

• GitHub Samples:
https://github.com/CiscoDevNet/webex-
contact-center-api-samples

© 2023 Cisco and/or its affiliates. All rights reserved. Cisco Confidential

You might also like