Created
June 18, 2010 18:47
-
-
Save PeterBloom/444040 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This script is called via HTTP. | |
options = { :channel => "VOICE", | |
:answerOnMedia => false, | |
:timeout => 30.0, | |
:callerID => "6502916707" | |
} | |
# Make an outbound call with the above options. | |
event = call 'tel:+1' + $numberToCall, options | |
if event.name == 'answer' | |
log 'Outgoing call gets answered by ' + event.value.calledID | |
wait(2000) | |
say ("<prosody rate='-40%'>This is a test application from Peter Bloom | |
</prosody>",{:voice => "allison"}) | |
wait(800) | |
say ("<prosody rate='-40%'>This is a sound file | |
</prosody>", | |
{:voice => "dave"}) | |
wait(500) | |
say ("http://hosting.tropo.com/46294/www/audio/Whoareyou.mp3") | |
wait(800) | |
say ("This is fast speech",{:voice => "allison"}) | |
wait(800) | |
say ("<prosody rate='-80%'>This is slower speech | |
</prosody>", | |
{:voice => "allison"}) | |
wait(800) | |
event = record('Say something after the beep.', | |
{ :beep => true, | |
:recordFormat => "audio/wav", | |
:timeout => 5, | |
:recordURI => 'ftp://ftp-internal.voxeo.net/www/audio/testtemp.wav', | |
:recordUser => 'PeterBloom', | |
:recordPassword => '123456', | |
:transcriptionID => event.value.calledID, | |
:transcriptionOutURI=> 'mailto:[email protected]' | |
}) | |
wait(800) | |
say ("<prosody rate='-40%'>I am going to play back your recording now</prosody>",{:voice => "dave"}) | |
wait(800) | |
say ("http://hosting.tropo.com/46294/www/audio/testtemp.wav") | |
wait(800) | |
say ("<prosody rate='-50%'>Thank you goodbye</prosody>",{:voice => "allison"}) | |
hangup | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment