One of our clients recently started to get frustrated with VOIP/Telco companies that wanted to charge him an arm and a leg to configure his phones to do something customized. Luckily there are some new cloud-based communication web services with killer APIs like Twillio and Tropo. With these tools any developer can code call functionality into their application, or perhaps even mirror the functionality of a call system with a little Ruby Sinatra Application.
The following video is exactly that Ruby Sinatra App, developed by our own Jacob Swanner:
Sorry, I can’t show you the code how we did it (this is client work). However, let me show you an example of the API code. When someone calls in to the number your service gives you, the cloud service makes a call to your Ruby app and your Ruby app tells Twillio / Tropo what to do. Here’s a quick example from Twillio:
As you can see, the user will be played a Greeting and then asked for their zipcode. Once that zipcode has been captured the cloud service calls back to your Ruby app with the entered information, your Ruby app would retrieve the weather information (inside your controller), then perhaps render this XML View:
There are prettier ways to write XML in Ruby, but you get the picture. The response gets read back to the caller. Both the Twillio documentation and the Tropo documentation are quite useful, especially the examples and both services are reasonably cheap.
If you need any help implementing a call center / voice interface to your app, feel free to give us a ring. We love this stuff.
Related posts:

Just posted a screencast showcasing a Call Center @envylabs recently developed using Ruby and Sinatra. http://is.gd/6xvdT
This comment was originally posted on Twitter
Love the screencast, especially the harmonizing ringtones. Great job! I wish I could see the source ;)
Very cool! RT @greggpollack screencast showcasing a Call Center @envylabs recently developed using Ruby and Sinatra. http://is.gd/6xvdT
This comment was originally posted on Twitter
Top Ruby Article: Ruby Call Center: http://bit.ly/6lSnl4
This comment was originally posted on Twitter
Posted a screencast showcasing a Call Center @envylabs recently developed using Ruby and Sinatra. http://is.gd/6xvdT (via @greggpollack)
This comment was originally posted on Twitter
A screencast showcasing a Call Center @envylabs recently developed using Ruby and Sinatra. http://is.gd/6xvdT (via @greggpollack)
This comment was originally posted on Twitter
Ruby Call Center http://ow.ly/XYp5
This comment was originally posted on Twitter
Ruby Call Center http://j.mp/4Vkjec
This comment was originally posted on Twitter
Ruby Call Center http://bit.ly/8GicBA cool!
This comment was originally posted on Twitter
Ruby Call Center « Envy Labs: If you need any help implementing a call center / voice interface to your app, feel … http://bit.ly/6IweFN
This comment was originally posted on Twitter
Ruby Call Center – Envy Labs: http://bit.ly/7WEVC5 – Awesome doesn’t even begin to describe this. #sinatra
This comment was originally posted on Twitter
Ruby Call Center http://blog.envylabs.com/2010/01/ruby-call-center/ лол
This comment was originally posted on Twitter
Creating a Call Center application using Ruby http://bit.ly/7UDCey
This comment was originally posted on Twitter
You guys couldn’t at least use something like blueprint to made it a little easier on the eyes?
Have a look at http://warvox.org/gallery.html , a parallel VoIP wardialer written in Ruby.
Call Center with Ruby/Sinatra http://snipr.com/u4kch #tuanix (via @pabloq)
This comment was originally posted on Twitter
Cool use of ruby, sinatra, and cloud services to create a call center: http://blog.envylabs.com/2010/01/ruby-call-center/
This comment was originally posted on Twitter
[...] Ruby Call Center, funny video featuring one of Envy Lab’s client jobs [...]
[API] Watch Ruby Call Center by Gregg Pollack : http://blog.envylabs.com/2010/01/ruby-call-center/
This comment was originally posted on Twitter
Hi Gregg,
Great demo, I love the “dialing strategy” design. You should start a barber shop quartet with Twilio, guaranteed to win a contest or two.
If you’d need any help or would like to chat, feel free to drop me an email.
Cheers,
-jeff
Twilio.com
Muy interesante este screencast sobre un mini call center como siempre d @greggpollack http://icio.us/i4j4hi
This comment was originally posted on Twitter
Funny screencast about a call center in Ruby: http://is.gd/6xvdT #in
This comment was originally posted on Twitter
Ruby Call Center http://bit.ly/cxCWBs
This comment was originally posted on Twitter
hilarious ring tones RT @ruby_news: Ruby Call Center http://bit.ly/cxCWBs
This comment was originally posted on Twitter
I have a project in private beta that also provides an XML API to take control of voip services. Any one interested in helping polish it can request an invite at beta.teliax.com.