SHARE



ABOUT THE AUTHOR


Terry Slattery
Terry Slattery, is a senior network engineer with decades of experience in the internetworking industry. Prior to joining Chesapeake NetCraftsmen as...
Read Full Bio >>
SHARE



Terry Slattery | September 01, 2016 |

 
   

Talking With 007

Talking With 007 James Bond helps me add Tropo voice interaction to my applications.

James Bond helps me add Tropo voice interaction to my applications.

Your organization has a neat new application but it needs to work with customers who don't have access to mobile clients. Why not voice-enable the application? You could create complex IVR processes using simple Python scripts within Cisco's Tropo cloud API platform. Or maybe you need a way to communicate with on-call staff to handle IT emergencies. You could use Tropo to make and provide basic information in the initial calls. In some situations, text messaging might be a better choice, and Tropo supports SMS, too.

Where does 007, James Bond, come into it? Hang on, we'll get there.

What Is Tropo?
Tropo is a voice and text-message programming framework that supports development in five languages -- Python, JavaScript, PHP, Ruby, and Groovy -- as well as via a Java API. I had the opportunity to work with Tropo while at Cisco Live in July, along with about 100 other participants. One of the things we learned was how to integrate voice functionality within a simple Python application. We created a simple application that accepted a call and allowed us to interact with it.

To help get developers started, Tropo has simple introductions called Quickstarts. Creating the app required very little programming. After a simple registration process to assign a free phone number, we wrote a short script to accept a phone call, say something, then play an MP3 recording. We did do all this in a one-line script:

    say("Guess what? https://www.tropo.com/docs/troporocks.mp3")

The How it works page has a similar example.


Source: Flickr

Talking With 007
After returning from Cisco Live, I decided to take a closer look at Tropo and work with some of the scripting features. I wanted to learn more about what was possible, and explore the idea that it would be ideal for handling alerts from network management applications.

I started at the Tropo website, and quickly found the page that documents the different languages and voices. Seeing a U.K. voice as one of the choices, I immediately thought of Sean Connery as James Bond.

A simple process for registering the phone number allowed me to make and receive local calls (there are a number of restrictions, for obvious reasons). It was easy to get 007 to answer the phone. The process for answering the phone and playing a message is built into a single command:

    say("Hello, my name is Bond, James Bond. Thank you for calling.", {"voice":"Daniel"})

After a few hours learning additional commands and some conversations with the Tropo support team, I had an interactive script that could receive a call and provide a greeting, or that could call out, ask a question, listen for an answer, and play back the answer within a sentence. You'll need to replace the called number and the callerID with valid numbers in the call() function:

if currentCall:

    say("Hello, Mr. Bond is out of the office. Thank you for calling.", {"voice":"Kate"}) sys.exit()
else:
    call("+15555551212;postd=pp", {"voice":"Daniel", "callerID":'15555551212'})
    say("Hello. My name is Bond, James Bond.")
    log("Introduction done")
    result = ask("What is your favorite drink, Martini, Wine, or Vodka?", \ {"choices":"martini, wine, vodka"})
    say("Sam, please get us a " + result.value)
    log("Drink " + result.value) say("Thank you.")
    sys.exit()

I finally had a networking application that amused my wife, a remarkable achievement in the world of boring networking topics.

Beyond Bond
While making a short app to simulate talking to James Bond was fun, I wanted to look into some more serious applications of Tropo, too.

My first thought was a network management application interface that would place calls or send text messages to on-call staff when a major network event occurs. Information about the event easily could be placed in the call to identify the impacted device, interface, or application. The input capability could be used to perform additional actions, such as contacting others, launching an interactive chat room (Cisco likes to demonstrate Spark in combination with Tropo), or starting additional diagnostic processes.

I also can see using it to keep me updated on long-running system jobs for processes like database replication. I could create a script to send a notification when the replication isn't finished in its typical runtime. A Tropo app could report that a job is delayed, and show how much progress it has made, its current rate of progress, and how long it is expected to continue to run. That's much better than having the system send an alert without the basic information to make decisions.

Tropo also supports conference calling, which is why Cisco demonstrates it in conjunction with Spark. When a problem requires a group to troubleshoot, an app could create a Spark room and initiate a conference call with all the required team members. The response time to understanding the problem is much shorter than with other notification methods.

Tropo offers a more complex and powerful Web API as well as the scripting interface shown above, but I didn't experiment with it. I was really interested in how simple the scripting interface was and how it hides a lot of the complexity of getting started with Tropo. I didn't have to find, download, and then import a variety of Python modules from GitHub. That made it easy to produce immediate results.

I did find some limitations in Tropo. I wanted to have 007 first ask me my name, then have him say it back to me. This isn't easily done in Tropo because it involves unconstrained voice-to-text conversion, which isn't currently supported. The choice selection mechanism seems to work well, but may create problems when a large set of choices is required.

I was told that one phone number can support up to 200 incoming concurrent calls while handling outgoing calls. That's what makes the above script work, using the "currentCall" variable to switch between incoming and outgoing processing.

Troubleshooting could be streamlined more. The log file is very detailed, and it is best to download the resulting log file and use a text editor to browse through it. I found that the level of detail sometimes made it difficult to find the error messages.

Tropo is an interesting tool that I'm looking forward to incorporating into some of our business practices.





COMMENTS




Enterprise Connect Orlando 2018
March 12-15 | Orlando, FL

Connect with the Entire Enterprise Communications & Collaboration Ecosystem


Stay Up-to-Date: Hear industry visionaries in Keynotes and General Sessions delivering the latest insight on UC, mobility, collaboration and cloud

Grow Your Network: Connect with the largest gathering of enterprise IT and business leaders and influencers

Learn From Industry Leaders: Attend a full range of Conference Sessions, Free Programs and Special Events

Evaluate All Your Options: Engage with 190+ of the leading equipment, software and service providers

Have Fun! Mingle with sponsors, exhibitors, attendees, guest speakers and industry players during evening receptions

Register now with code NOJITTEREB to save $200 Off Advance Rates or get a FREE Expo Pass!

January 24, 2018

Communications, collaboration, and contact center systems are all being delivered from the cloud, to more enterprises each year. With the cloud growing in strategic importance, the question is what

December 13, 2017

The two major vendors in the Unified Communications space, Cisco and Microsoft, are both strongly promoting their cloud UC deployments. If cloud UC is on your enterprises roadmap, but you dont want

November 29, 2017

As video conferencing use rises in the enterprise, businesses are looking for ways to bring this technology out of traditional conference room and make it more broadly accessible. That's made the h

December 20, 2017
Kevin Kieller, partner with enableUC, provides advice on how to move forward with your Skype for Business and Teams deployments.
December 20, 2017
Zeus Kerravala, principal analyst with ZK Research, shares his perspective on artificial intelligence and the future of team collaboration.
December 20, 2017
Delanda Coleman, Microsoft senior marketing manager, explains the Teams vision and shares use case examples.
November 30, 2017
With a ruling on the FCC's proposed order to dismantle the Open Internet Order expected this month, communications technology attorney Martha Buyer walks us through what's at stake.
October 23, 2017
Wondering which Office 365 collaboration tool to use when? Get quick pointers from CBT Nuggets instructor Simona Millham.
September 22, 2017
In this podcast, we explore the future of work with Robert Brown, AVP of the Cognizant Center for the Future of Work, who helps us answer the question, "What do we do when machines do everything?"
September 8, 2017
Greg Collins, a technology analyst and strategist with Exact Ventures, delivers a status report on 5G implementation plans and tells enterprises why they shouldn't wait to move ahead on potential use ....
August 25, 2017
Find out what business considerations are driving the SIP trunking market today, and learn a bit about how satisfied enterprises are with their providers. We talk with John Malone, president of The Ea....
August 16, 2017
World Vision U.S. is finding lots of goodness in RingCentral's cloud communications service, but as Randy Boyd, infrastructure architect at the global humanitarian nonprofit, tells us, he and his team....
August 11, 2017
Alicia Gee, director of unified communications at Sutter Physician Services, oversees the technical team supporting a 1,000-agent contact center running on Genesys PureConnect. She catches us up on th....
August 4, 2017
Andrew Prokop, communications evangelist with Arrow Systems Integration, has lately been working on integrating enterprise communications into Internet of Things ecosystems. He shares examples and off....
July 27, 2017
Industry watcher Elka Popova, a Frost & Sullivan program director, shares her perspective on this acquisition, discussing Mitel's market positioning, why the move makes sense, and more.
July 14, 2017
Lantre Barr, founder and CEO of Blacc Spot Media, urges any enterprise that's been on the fence about integrating real-time communications into business workflows to jump off and get started. Tune and....
June 28, 2017
Communications expert Tsahi Levent-Levi, author of the popular BlogGeek.me blog, keeps a running tally and comprehensive overview of communications platform-as-a-service offerings in his "Choosing a W....
June 9, 2017
If you think telecom expense management applies to nothing more than business phone lines, think again. Hyoun Park, founder and principal investigator with technology advisory Amalgam Insights, tells ....
June 2, 2017
Enterprises strategizing on mobility today, including for internal collaboration, don't have the luxury of learning as they go. Tony Rizzo, enterprise mobility specialist with Blue Hill Research, expl....
May 24, 2017
Mark Winther, head of IDC's global telecom consulting practice, gives us his take on how CPaaS providers evolve beyond the basic building blocks and address maturing enterprise needs.
May 18, 2017
Diane Myers, senior research director at IHS Markit, walks us through her 2017 UC-as-a-service report... and shares what might be to come in 2018.
April 28, 2017
Change isn't easy, but it is necessary. Tune in for advice and perspective from Zeus Kerravala, co-author of a "Digital Transformation for Dummies" special edition.
April 20, 2017
Robin Gareiss, president of Nemertes Research, shares insight gleaned from the firm's 12th annual UCC Total Cost of Operations study.
March 23, 2017
Tim Banting, of Current Analysis, gives us a peek into what the next three years will bring in advance of his Enterprise Connect session exploring the question: Will there be a new model for enterpris....
March 15, 2017
Andrew Prokop, communications evangelist with Arrow Systems Integration, discusses the evolving role of the all-important session border controller.
March 9, 2017
Organizer Alan Quayle gives us the lowdown on programmable communications and all you need to know about participating in this pre-Enterprise Connect hackathon.
March 3, 2017
From protecting against new vulnerabilities to keeping security assessments up to date, security consultant Mark Collier shares tips on how best to protect your UC systems.
February 24, 2017
UC analyst Blair Pleasant sorts through the myriad cloud architectural models underlying UCaaS and CCaaS offerings, and explains why knowing the differences matter.
February 17, 2017
From the most basics of basics to the hidden gotchas, UC consultant Melissa Swartz helps demystify the complex world of SIP trunking.
February 7, 2017
UC&C consultant Kevin Kieller, a partner at enableUC, shares pointers for making the right architectural choices for your Skype for Business deployment.
February 1, 2017
Elka Popova, a Frost & Sullivan program director, shares a status report on the UCaaS market today and offers her perspective on what large enterprises need before committing to UC in the cloud.
January 26, 2017
Andrew Davis, co-founder of Wainhouse Research and chair of the Video track at Enterprise Connect 2017, sorts through the myriad cloud video service options and shares how to tell if your choice is en....
January 23, 2017
Sheila McGee-Smith, Contact Center/Customer Experience track chair for Enterprise Connect 2017, tells us what we need to know about the role cloud software is playing in contact centers today.