Initiating outbound calls from your application is incredibly simple with Teleku! All you need to do is call the following URL and pass it the phone number and extension that you wish to dial in the URL. Teleku will respond with the status of the dial attempt (success or failure).
http://teleku.com/dial/number/extension?apikey=123abc
Example:
http://teleku.com/dial/6025551212/1?apikey=123abc
http://teleku.com/dial/1234@sipgateway.com/1?apikey=123abc
Note: API Keys are now required for all outbound phone calls and SMS messages. You can find your API Key listed in your Dashboard.
Teleku will call the number (phone number on Samurai platform or SIP address on Ninja platform) specified in the URL and run the requested extension script. You can easily connect two calls using the PhoneML <transfer> tag illustrated in the example below:
Thanks for calling Acme Labs. 480-555-1212
Note: You can specify the callerid for the outbound call by adding it to the end of the URL as a query parameter as follows:
http://teleku.com/dial/6025551212/1?callerid=14808611000&apikey=123abc
Note: You can also wait for the results of the dial to be returned to your application by adding wait=true to the end of the URL as a query parameter as follows:
http://teleku.com/dial/6025551212/1?callerid=14808611000&wait=true&apikey=123abc
Note: We now can return call detection from the dial to be returned to your application by adding detect=true to the end of the URL as a query parameter as follows:
http://teleku.com/dial/6025551212/1?callerid=14808611000&detect=true&apikey=123abc
A special form "detection" parameter will be returned on your extension call that will provide the results of the call answer. Possible results inculde:
Note: We now allow you to pass a string of data from the dial to be returned to your application in the "data" parameter by adding data=whatever+you+want+to+pass to the end of the URL as a query parameter as follows:
http://teleku.com/dial/6025551212/1?callerid=14808611000&detect=true&apikey=123abc&data=whatever
Here is the Ruby/Sinatra example from Teleku Video #7:
' end get '/dial' do RestClient.get 'http://teleku.com/dial/' + params[:number] + '/37?callerid=4808611000&apikey=123abc' end post '/' do builder do |xml| xml.instruct! xml.phoneml do xml.speak "teleku at your service" xml.transfer "6232523425" end end endrequire 'rubygems' require 'sinatra' require 'rest_client' require 'builder' get '/' do 'Enter a number to dial
You can also now simply dial and connect two numbers using the Connect method as follows:
http://teleku.com/connect/source_number/target_number?apikey=123abc
This solution allows your Web application to initiate a phone call to the source_number and once connected, place a call to the second phone number and bridge them together without any programming logic! Note: This method is evolving and may undergo changes.
Copyright © 2010 - All Rights Reserved - GetVocal, inc. - Trademarks belong to their respective companies
Template by OS Templates & Artwork by Sumo Web Works