IVR Application in Lua for Freeswitch
5:57 pm in FreeSWITCH, Lua by admin
1. Create a New file name 01_Custom.xml and add the following new extension:
<extension name=”Read Back Entered Digits”>
<condition field=”destination_number” expression=”^(9910)$”>
<action application=”lua” data=”test1.lua”/>
</condition>
</extension>
2. Save the file. Launch fs_cli and issue reload_xml, or press F6.
Our Dialplan is now ready to call the Lua script named test1.lua. Create this new script as follows:
1. Using your text editor, create test1.lua in the freeswitch/scripts/ directory and add the following lines:
– test1.lua
– Answer call, play a prompt, hangup– Set the path separator
pathsep = ‘/’ — Windows users do this instead:
– pathsep = ‘\’–Answer the call
session:answer()–Create a string with path and filename of a sound file
prompt = “ivr” .. pathsep .. “ivr-welcome_to_freeswitch.wav”– Print a log message
freeswitch.consoleLog(“INFO”,”Prompt file is ‘” .. prompt .. “‘\
n”)–Play the prompt
session:streamFile(prompt)– Hangup
session:hangup()
2. Save the file.
Now dialer 9910 and you will get IVR.





Great website…
[...]we like to honor many other internet sites on the web, even if they aren’t linked to us, by linking to them. Under are some webpages worth checking out[...]……
Online Article……
[...]The information mentioned in the article are some of the best available [...]……
Thanks,I’m bookmarking your blog and I’ll be back. Thanks again!การ์ตูนแปลไทย
this page showed up in my ……
I saw this really great article today……
Best Food Resources…
I am trying to collect a good sources about food discussions. Found this blog very useful….
Awesome website…
[...]the time to read or visit the content or sites we have linked to below the[...]……
I rece]ived fantastic data from the blog.ของขวัญ
Wow…..
I really appreciate this post. I’ve been looking everywhere for this! Thank goodness I found it on Bing. You’ve made my day! Thank you again! “All that is gold does not glitter not all those that wander are lost.” by J. R. R. Tolkien….
Many thanks for sharing this one particular. A ought to go through write-up.fun88t
Sources…
[...]check below, are some totally unrelated websites to ours, however, they are most trustworthy sources that we use[...]……
Check it out guys:…
I saw this really great post today….