Have you ever wanted to set a timer on a conference call and pop-in at a certain time to either:

1) announce something, say, every 15 minutes;
2) let participants know that they have 2 minutes remaining; or
3) ask them a question or survey?

This is easy to do by connecting Tropo applications! I created a quick demo using the Tropo Scripting API that allows people to call into a Tropo phone number, SIP address, or Skype address and after x seconds announce that they have two minutes remaining. The demo code below is written in Ruby and it uses threading to start a timer and wait/sleep until x seconds has transpired. Once the timer expires, it calls and conferences a second Tropo application via its SIP address and simply announces the warning message. You could easily extend the second Tropo application to prompt the user to answer a single question or a take a poll/survey and report their answers back to the main application either via a database or via SIP headers on the transfer back to the application.

Here’s the Ruby source code on the main application:

#Method to create timeStamp as our conferenceID
def get_conference_id() timeVar = Time.new returnValue = timeVar.strftime("%Y%H%M%S") return returnValue
end conferenceOptions={ :mute=>false, :playTones=>true, :leaveprompt=>"beep" } begin #Create conference ID conferenceID = get_conference_id() log "@"*5   "User has answered" #Create second thread for second for timer and announcements Thread.new do log "@"*5   "Start second tread" sleep 10 call 'sip:9996137086@sip.tropo.com', { :onAnswer=>lambda{|event| log "@"*5 "answered join conference" newCall = event.value newCall.conference(conferenceID,conferenceOptions) } } end #thread say 'You are now in conference.' conference(conferenceID,conferenceOptions) end

Here’s the Ruby source code of the announcement application:

say "you have two minutes remaining."

Note the SIP address used in the main application. It’s the SIP address assigned to your second announcement application by Tropo when it’s created. Every Tropo application automatically gets a SIP address, iNum address, Skype address, and Phono address assigned to it upon creation. You can transfer and conference calls app-to-app using SIP addresses and even pass data between them using SIP headers. How’s that for webscale?!

©2011 The Tropo Blog. All Rights Reserved.

.

Related posts:

  1. Tutorial: Click-to-Call applications (w/ conferencing)
  2. Customer Service Hotline
  3. Conference Call Apps Made Easy with Tropo

Originally from All Voxeo Blogs Feed