Amazon Connect Quota Visibility

Not being able to see what your applied quota settings were has been a huge sore spot with Connect. We’ve resorted to keeping track of quotas on a spreadsheet and having AWS support provide updated numbers every 6 months. However, this is not scalable and generally a pain. I was very please when the following announcement was made, which states:

You can now view applied quota values for resources within each of your Amazon Connect instances using AWS Service Quotas. …

I immediately went to one of our Connect instances and was very disappointed at first. Because, the way AWS decided to present the applied quota as it’s not obvious. If you go to the Service Quotas > AWS Services> Amazon Connect. You see all applicable quotas for Connect. In this case let’s focus on Quick Connects. Notice that the “Applied quota value” is still the default.

Amazon Connect Service Quotas

Amazon Connect Service Quotas

If you click on the actual quota. You will still see the default at the top, but at the bottom right you’ll see the true applied number.

Quick Connects Per Instance Service Quota

Quick Connects Per Instance Service Quota

I’m happy this is here, but I wish AWS would just go the extra mile and not require us to click on the actual quote to see the true number. I’ve not validated this via the CLI, but I am hopeful it’s more obvious there.

~david

Read Only Script Editor Access in PCCE

This question came up this past week and I had a nagging suspicion it wasn’t the case and spent some time trying to get it to work. In the good old days of UCCE Config Manager had the Feature Control set capability which allowed users to have a limited view to the ICM Script Editor. This was great for those type of users who understood the scripting, but were not trained up enough to make changes.

The PCCE 11 documentation seems to hint at this being possible. You create a read-only Administrator and then you give them Script Editor access. I understand this is a huge leap, but it is not an unreasonable assumption. However, the 12.6 documentation removed that information as well removed the ability of having read-only administrator. It appears that your only option in CCE Admin > Users > Roles is to remove all access to Script Editor The following role:

Capture

Has this effect:

Capture1

If you add the Script Editor role again your user has full access to Script Editor again. So to summarize, it’s not possible to have a read only Script Editor user. I would love to be proven wrong. For now I hope this helps others out there looking for the answer.

~david

A Deeper Dive Into the Cisco Finesse Layout

I’ve been helping a customer migrate from Cisco’s Unified Contact Center Enterprise (UCCE) 11 to UCCE 12 and Amazon Connect. Depending on the complexity and needs of the business they might move to UCCE 12 or they might be moved to Connect. This has caused me to spend some time thinking of the most efficient way to migrate configuration between multiple environments and ensure everything is up to date.

One of the components which I’ve done a lot of work with, but never really looked at too closely is the Finesse layout. In this post we’ll break down what layouts are, how they work, and provide some interesting pieces of trivia around Finesse. This information is up to date as of Finesse 12.5. Make sure you reference the documentation for your specific version.

BACKGROUND

To start, the Finesse front end, what the agent and administrators see, are based on the OpenSocial specification. What this specification provides is a runtime environment where trusted and untrusted web components or gadgets can interact with the hosting platform, 3rd party services, or with other gadgets. Said differently, this specification sets the rules. It dictates how components will look, where they are placed, and what they can do. While the OpenSocial foundation no longer exists. At one point the foundation was moved under W3C where it was then set to inactive in 2018. The latest specification can be found living here.

An interesting bit of trivia. One of the original developers of OpenSocial was none other than MySpace. Remember them?

You will hear the word gadget multiple times and it is worth defining as it is a core block of Finesse. The best way to think about a gadget is as an application which can be embedded inside another application. If you’re familiar with widgets, you should consider gadgets to be very similar in nature. Now, something a lot of us fail to remember is that all of Finesse is actually one big gadget with a lot of smaller gadgets inside. While you can’t replace the whole gadget that runs on the Finesse server, you can add your own gadgets inside the Finesse gadget using a layout.

XML

The very first thing you need to understand is that like all things Cisco Contact Center Enterprise and Express you must be very familiar with working with XML. While XML has lost a lot of favor in the last few years, when it comes to desktop layouts, using XML makes a lot of sense. While editing a layout can be confusing, Cisco does a good job of assisting with basic syntax checking to catch simple errors. In an ideal world there would be a visualizer that previews the changes you’re making to your layout before saving them. Maybe one day.

The XML file loaded must conform to this schema. The schema is what dictates what tags your layout can have as well as naming conventions for components. 

The XML schema has the following elements defined. These are not in the order they appear in the schema, but I’ve ordered in a hierarchical way to better highlight their relationship. Additionally, there are other elements included in the schema which are not covered below. The list below shows the most important elements to read through to better understand a Finesse layout:

  • finesseLayout: Think of this as the outer boundaries of the whole desktop.
  • layout: The actual layout.
  • role: Role definition.
  • tabs: Grouping of tabs.
  • tab: Each single tab.
  • page: The grouping of gadgets within that page referenced by a tab.
  • columns: Grouping of columns.
  • column: Each single column.
  • gadget: The actual gadget URL.

Another interesting bit of trivia. The XML schema allows for three types of Finesse users: Agent, Supervisor, and Admin. While the desktop layout never references Admins the schema has an additional role that Cisco could later enable or currently uses for publicly restricted functions.

DESKTOP LAYOUTS

The layout is what dictates what will be loaded when an agent or supervisor login to Finesse. More importantly, it allows for the organization of different gadgets on the page to fit your contact center requirements. At its core the layout includes the following sections:

  • Horizontal Header: This section is the top bar across Finesse. And includes a Logo, Product Name, Agent State for Voice, State for Digital Channels, Dialer Component, and Identity Component. For most installations you’ll only ever see the logo, name, voice state, and identity components.
  • Alternate Hosts
  • Title and Logo in Header
  • Headless Configuration: If your gadget does not require a UI.
  • Customized Icons

Interesting tip: Most gadgets can be dragged and dropped and resized by agents, however out of the box this feature is disabled. To enable it look at the enableDragDropAndResizeGadget config key.

DEFAULT GADGETS

Out of the box you should see the following gadgets:

  • Call Control
  • Queue Statistics
  • Agent Call History
  • Agent State History
  • Customer Context
  • Team Data (Supervisor)

Additionally there are a good bit of disabled gadgets that you can use they all revolve around bringing CUIC data, specifically Live Data, to the agent desktop.

I hope to have time to dive deeper on this topic. There are so many little morsels of information every where you look, you just have to dig a little deeper to find them.

~david

Find specific phone number in Finesse phone books through the Finesse API using Python

Here’s a quick Python script that will allow you to go through each phone book in Finesse and identify the phone book that has the phone number(s) you’re after. Just fill in your information ‘<>’ and update the numbers you want to find.

import requests # for using API
from requests.auth import HTTPBasicAuth
import xml.etree.ElementTree as ET # for parsing XML

requests.packages.urllib3.disable_warnings() #If using a self signed certificate

rootURL = ‘<>’ # e.g. http://finesse.company.com
phonebooksURL = ‘/finesse/api/PhoneBooks’
username = ‘<>’ #Finesse admin username
password = ‘<>’

headers = {‘Accept’: ‘application/xml’, ‘Content-Type’: “application/xml”}

phonenumbers = [‘5555551234’, ‘5555551235’, ‘5555551236’, ‘5555551237’] #phone numbers you want to find.

res = requests.get(rootURL+phonebooksURL, headers= headers, verify=False, auth=HTTPBasicAuth(username, password))
print(res.status_code)

root = ET.fromstring(res.content)

for phonebooks in root:
phonebookId = phonebooks[3].text
res = requests.get(rootURL+phonebookId+’/Contacts’, headers=headers, verify=False, auth=HTTPBasicAuth(username, password))
print(res.status_code)
root = ET.fromstring(res.content)
for contacts in root:
for number in phonenumbers:
if number in contacts[3].text:
print(phonebooks[2].text, contacts[3].text)

~david

Audacity Export Encoding

Generating telephony audio prompts with Audacity on Windows and Mac

This blog post should be pretty basic, but in the last few months I’ve had two different parties ask me about this so I figured I would capture this for posterity. If you want to use Audacity to convert your audio file to a compatible format that can play in your Cisco UCCX or CCE call center or any system that uses CCITT u-Law 8.000 Khz, 8 Bit, Mono format.

Assuming you’re running the latest version of Audacity (I’m using version 3.1.3 on both Windows and Mac). Open the audio file you wish to convert. There are 3 settings you must change.

  • The format needs to be set to PCM 16-bit.
  • Project Rate (Hz) needs to be set to 8000.
Audacity Format and Rate

Audacity Format and Rate

  • File > Export > Export as WAV and ensure you set the right encoding.
Audacity Export Encoding

Audacity Export Encoding

That’s it, you’re good to go.

~david

2022 Cisco Designated VIP

I am pretty jazzed for making this awesome list for the second year in a row. The amount of brain power that you can find in the Cisco community forums is insane and being grouped with them is an honor. I really appreciate the recognition from Cisco.

As an added bonus I looked back for my very first post on the community forums. It happened on 02/14/2006, almost 16 years ago. I don’t remember the specific project I was working on, but it involved IPCC Express 3.x… :)

~david

How does Amazon Connect CCP Agent Login and Logout Work

I didn’t think a call center platform could make the topic of an agent login and logout interesting, but Amazon Connect has figured out a way to make me question my sanity with the design decision they have made.

We are going to do a deep dive into some of the uniqueness and outright strange behavior the CCP has when it comes to agent login and logout. This assumes you’re running the out of the box CCP, which means zero customization. Additionally, we’re going to be looking at 5 different screens at the same time to get an overall picture of what is going on and it’s impact to reporting. We will be looking at the Amazon Connect Dashboard, CCP, Real Time Agent reporting, Login/Logout report and Agent activity audit report.

Login to CCP

There are two ways that agents could login to CCP. The first is by logging into the Connect Dashboard (htts://<your-instance>.my.connect.aws/) then having agents launch CCP from there here’s what you need to know. The second way is to go to the CCP directly (https://<your-instance>.my.connect.aws/ccp-v2). Let’s walk through the first method step by step and see some of the reporting implications.

Step 1: A dashboard login:

  • Will show up in the Login/Logout report.
  • Will not show up in the Real Time Agent report.
  • Will not show up in the Agent activity audit report.

Why is this important? From the Dashboard to taking a call center call, the agent still needs to launch CCP and go into the Available state. I would argue that a better metric of login would be when the agent launches the CCP and not just logs into the Dashboard. The documentation for the Login/Logout report state this:

The Login/Logout report displays the login and logout information for the users in your contact center (for example, agents, managers, and administrators).

So the documentation is aligned with the behavior you see, but I would argue that, when it comes to agents, this report is misleading as an agent still has a few steps to follow before they are ready to take a call. Now, if you open the Agent activity audit report you will not see any data either which makes sense based on the Login/Logout report. Thankfully, both reports line up. Now, let’s get our agent from the Dashboard to CCP. By default the CCP should be in the Offline state.

Step 2: Launch CCP and:

  • The Login/Logout report doesn’t change as this is based on the Dashboard login.
  • You still will NOT show up in the Real Time Agent report.
  • You still will NOT show up in the Agent activity audit report.

Our agent has logged in to the Dashboard, launched CCP and is in an Offline state, but we’re still not seeing anything outside of the Login/Logout report. I would have expected the Real Time Agent report to show me the state of the agent, but that’s not happening. What’s even more infuriating is that if the agent changes states and then goes back to Offline, the Real Time Agent metrics have data about my agent. So why is Offline after login any different than going from one state to Offline state? To be fair, the agent will drop off from the statistics in about 3 minutes, however I think AWS should change this behavior and by default show any agent who is logged in and Offline to make things more consistent.

Logout of CCP

You would think that logout would be much easier, but there are still a few gotchas on this. The biggest thing to remember is that just closing the CCP window will not log you out. Another thing to consider is that a CCP logout will put you in Offline first then log you out. This is important to note if you have custom states you want to use for logout. However, if you are in the Dashboard and you launched the CCP and you logout from the Dashboard it will not properly log you out of the CCP. The CCP will eventually give you a login screen, but:

  • Real Time Agent metrics will still show you in the last state you were in.
  • Login/Logout report will show you logged out.
  • Agent Activity audit will still show you in the last state you were in.

Make it Better

Here are what I believe to be some simple suggestions to make this experience better. I hope that someone at AWS takes some of these and puts them in the next sprint.

  1. Offline state shows up in Real Time Agent metrics.
  2. The Routing Profile allows for configuring the default agent state upon login. This will put agents in any state when they first login.
  3. Dashboard or CCP logout behave the same way and reflect correctly across all reports.

Login and Logout at a Glance

Action Real Time Agent Login/Logout Report Agent Activity Audit
CCP Launch No Data Login time recorded either from Dashboard or CCP login No Data
CCP State Change State Data No Change State Data
Dashboard Logout Previous State Continues Logout time recorded No Data
CCP Logout Offline for about 3 minutes then stats disappear. Logout time recorded Offline State

~david

Obtained the AWS Solution Architect Associate Certification

I wanted to capture my experience working towards attaining the AWS SAA certification in hopes that this helps others on the same journey. This information is up to date as of 12/06/2021.

BACKGROUND

I first started working on getting the SAA back in middle 2020. I am the type that I like to  book the exam and then start planning for it. So, I booked the exam for August 19, 2020. At the time I used Adrian Cantril’s course. Which, I’ll be honest is great, very detailed. However, for me I was not ready for that type of detail and it was hard for me to focus and make time for the videos. I started strong, but started falling behind and was never able to catch up. On my first attempt I failed.

AWS SAA Failed Report

AWS SAA Failed Report

GETTING OVER THE HUMP

In the summer of 2021, on my city’s Slack, a few of us started talking about wanting to renew or pass an AWS certification. I put together a quick Google Sheet for people to talk about what they were trying to achieve and why. From there we had an initial meeting in early July and then decided to meet every Monday. One Monday in person and the next virtually via Webex. We ended with 4 total participants. 3 of us going for the SAA and 1 for Security. This was great as it created a constant reminder that I needed to study and stay with the group. I highly recommend to join or start a study group. The extra motivation helped me stay on track.

RESOURCES

As a group we talked about what resources worked best and compared notes about what we’ve checked out and what we liked/disliked about them. At the end of the day we all focused on a single primary resource. I personally supplemented my studies with a few other just to get multiple perspectives. Here’s what I used and in the order I used them:

A Cloud Guru (primary resource)

Tutorials Dojo Study Guide eBook (I printed this out and had it bound and would keep next to my bed to review the parts I felt that I needed further review)

Tutorials Dojo SAA Practice Exams

r/AWSCertifications

I enjoyed ACG’s video course. The videos were short and full of information and while the labs were ok, the gold was found in the videos alone. The TD eBook was good too, but I would skip it if you want to save money. Finally, the week before the exam I would go through practice exam question and read in detail the description for the questions I failed. Additionally, I would then go to the AWS documentation and get a bit more in depth to hopefully gain some new knowledge. I kept an eye on Reddit to see what others who had taken the test had to say about the topics covered. This allowed me to focus my studies. Personally, I feel that the practice exams was what got me to pass the exam. Not only because I was very used to the question style, but I was able to get a good feel for spotting the gotchas in the answers.

My exam had a lot of EFS, auto scaling, application and network load balancing. Good luck!

~david

PS: From our group all 3 passed the SAA and in a few days the last member of our study group will take the security exam and I’m sure will pass.

Adding Text to Speech to Your IVR Using SaaS (Google Cloud Functions)

I’ve been on a text-to-speech and speech-to-text kick lately. My last post talked about using AWS S3 and Amazon Transcribe to convert your audio files to text and in previous articles I’ve covered how to create temporary prompts using Poly so you can build out your contact center call flows. Well, now we’re going to expand our use case to allow a traditional on premise call center to leverage the cloud and provide dynamic prompts. My use case is simple. I want my UCCX call center to dynamically play some string back to my caller without having to use a traditional TTS service.

First, this is not new in any way and other people have solved this in different ways. This Cisco DevNet Github repo provides a method to use voicerss.org to generate TTS for UCCX. However, this process requires loading a jar file in order to do Base64 decoding. Then there’s this Cisco Live presentation from 2019, by the awesome Paul Tindall, who used a Connector server to do something similar. To be fair the Connector server allowed for a ton more functionality than what I’m looking for.

Screen Shot 2021-09-15 at 3.38.30 PM

Cisco Live Presentation

Second, I wanted this functionality to be as easy to use as possible. While functionality keeps getting better for on premise call center software there are still limitations around knowledge to leverage new features and legacy version that can’t be upgraded that makes it harder to consume cloud based services. I wanted the solution to require the least amount of moving parts possible. That means no custom Java nor additional servers to stand up.

The solution I came up with leverages Google’s cloud (GCP) specifically Cloud Functions. However, the same functionality can be achieves used AWS Lambda or Azure’s equivalent. At a high level we have an HTTP end point where you pass your text string to and in return you will get a wav file in the right format which you can then play back.

Blank diagram

Flow Diagram

The URL would look something like this:

https://us-central1-myFunction.cloudfunctions.net/synthesize_text_to_wav?text=American%20cookies%20are%20too%20big

The Good Things About This

  • Pay as you go pricing for TTS. Looking at the pricing calculator a few hours of TTS a month would run under $2.00/month.
  • Infinitely scalable. If you’re handling 1 call or 100 calls your function will always return data.
  • Easy to use.

The Bad Things About This

  • There is a delay between making the request and getting the wav file. I’ve seen as long as 7 seconds at times. I would only use this in a very targeted manner and ensure it didn’t affect the caller experience too drastically.
  • Requires your on premise IVR to have internet access. Often time this is a big no no for most businesses.

Some initial testing with UCCX is showing some positive results. I’m going to investigate if there’s a way to accelerate the processing in order to keep the request and response in under 3 seconds as well as adding the ability to set language, voice, and even SSML via arguments. If you want to build this yourself here’s the code for the function.

def synthesize_text_to_wav(request):
"""Synthesizes speech from the input string of text."""
text = request.args.get('text')

client = texttospeech.TextToSpeechClient()
input_text = texttospeech.SynthesisInput(text=text)
voice = texttospeech.VoiceSelectionParams(
language_code="en-US",
name="en-US-Standard-C",
ssml_gender=texttospeech.SsmlVoiceGender.FEMALE,
)
audio_config = texttospeech.AudioConfig(
audio_encoding=texttospeech.AudioEncoding.MP3
)
response = client.synthesize_speech(
request={"input": input_text, "voice": voice, "audio_config": audio_config}
)

src_file_path = '/tmp/output.mp3'
dst_file_path = '/tmp/output.wav'

# make sure dir exist
os.makedirs(os.path.dirname(src_file_path), exist_ok=True)

# The response's audio_content is binary.
with open(src_file_path, "wb") as out:
out.write(response.audio_content)
print('Audio content written to file "output.mp3"')
AudioSegment.from_mp3(src_file_path).export(dst_file_path, format="wav", codec="pcm_mulaw", parameters=["-ar","8000"])
return send_file(dst_file_path

Be awesome!

~david

Transcribe Your Audio Files To Migrate to Amazon Connect

This is an update to an earlier post covering the same thing now with updated code.

As we are working our way out of Cisco UCCE to Amazon Connect we find ourselves needing to transcribe thousands of prompts. I wanted to revisit this piece of code to ensure it is still working. If you want to use this and are starting from scratch here are the steps you need to take:

– Install Studio Code
– Install Python 3.9
– Create the folder where you will keep your project.
– Create a virtual environment.
– Activate your virtual environment.
– pip install python-dotenv, boto3, pandas
– *Remove the profile_name or update it.
– Update the .env file with the region you’ll be using.

You can find the full source code here.

The script works like this: It creates an S3 bucket, grabs the first file, checks if the file is in S3 and uploads it, creates a transcription job, waits for the transcription to complete, grabs the results, writes a CSV. I’ve tried to catch as many potential errors as possible, but I’m sure there are some lingering. Expect the transcription to take around 1 minute per file. Assuming normal IVR prompts.

AWS Transcribe* I have many AWS profiles, which might not the be case for others. If you only have a single profile change this line session = boto3.session.Session(profile_name=’MyProfile’) to session = boto3.session.Session()

I hope this helps others.

~david