Skip to content

Instantly share code, notes, and snippets.

@ObjectIsAdvantag
Last active September 24, 2016 22:56
Show Gist options
  • Save ObjectIsAdvantag/1d7eff4067cc5d611c19a0910f88292c to your computer and use it in GitHub Desktop.
Save ObjectIsAdvantag/1d7eff4067cc5d611c19a0910f88292c to your computer and use it in GitHub Desktop.
/*
* Copyright (c) 2009 - 2015 Tropo, now part of Cisco
* Released under the MIT license. See the file LICENSE
* for the complete license
*/
// --------------------------------------------
// Simple example of recording
// --------------------------------------------
record("Leave your message after the beep. Thanks!",
{
beep:true, silenceTimeout: 5, maxTime:60, timeout:10,
onRecord:function(event)
{
// Note that by default, Tropo stores the recorded audio file on its runtime server. This temporary file cnnnot be accessed externally.
// Only your script will be able to read the audio file as it gets executed inside tropo hosting environment.
// for more info, check: https://www.tropo.com/docs/hosting-debugging-logs/audio
say("you said " + event.value );
}
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment