[Freeswitch-users] Building an IVR - Macro not found error
William Colls
william at williamcollsassoc.ca
Fri Sep 2 04:22:57 MSD 2016
Built from source. My IVR is derived from the demo_ivr, and the macros
are in a seperate file. ivr and macro files as shown below.
/usr/local/freeswitch/conf/ivr_menus/ourhouse_ivr.xml
<include>
<menu name="ourhouse"
greet-long="phrase:ourhouse_greet_long"
greet-short="phrase:ourhouse_greet_short"
invalid-sound="ivr/ivr-that_was_an_invalid_entry.wav"
exit-sound="voicemail/vm-goodbye.wav"
confirm-macro=""
confirm-key=""
tts-engine="flite"
tts-voice="rms"
confirm-attempts="3"
timeout="10000"
inter-digit-timeout="2000"
max-failures="3"
max-timeouts="3"
digit-len="4">
<entry action="menu-exec-app" digits="1" param="transfer 203 XML
default"/>
<entry action="menu-exec-app" digits="2" param="transfer 204 XML
default"/>
<entry action="menu-top" digits="9"/> <!-- Repeat this
menu -->
</menu>
</include>
/usr/local/freeswitch/conf/lang/en/ivr/ourhouse_macro.xml
<include>
<macros>
<macro name="ourhouse_greet_long" pause="100">
<input pattern="(.*)">
<match>
<action function="play-file"
data="/usr/local/freeswitch/recordings/thanks.wav"/>
<action function="play-file"
data="ivr/ivr-you_may_exit_by_hanging_up.wav"/>
<action "ivr" data="ourhouse_greet_short"/>
</match>
</input>
</macro>
<macro name="ourhouse_greet_short">
<input pattern="(.*)">
<match>
<action function="play_and_get_digits"
data="(3 4 3 2000 # ivr/ivr-enter_ext_pound.wav
/invalid.wav ext_dialed \d+ 500"/>
<!-- Menu option 1: Heather -->
<action function="play-file"
data="/usr/local/freeswitch/recordings/heather.wav"/>
<!-- Menu option 2: William -->
<action function="play-file"
<!-- menu option 3: Contact information -->
<action function="play-file"
data="/usr/local/freeswitch/recordings/contact.wav"/>
<!-- menu option 9: replay the menu -->
<action function="play-file"
data="/usr/local/freeswitch/recordings/replay.wav"/>
</match>
</input>
</macro>
</macros>
</include>
On 2016-09-01 06:28 PM, Michael Jerris wrote:
> installing from source or packages? What file are you editing exactly and what have you added to it and where?
>
>> On Sep 1, 2016, at 6:21 PM, William Colls <william at williamcollsassoc.ca> wrote:
>>
>> Freeswitch 1.6.9
>>
>> debian Jessie 64 bit platform.
>>
>> New to Freeswitch and trying to build a small IVR. I am getting an error
>> when it tries to execute a phrase macro.
>>
>> From looking at freeswitch.xml.fsxml it appears that the macro is
>> loaded (reloadxml produces no errors).
>>
>> When I call into the switch, I can see the call being answered, and my
>> IVR is picked, up and executes with out error until switch_ivr_play
>> tries to play the macro. It then generates the error message "Can't find
>> macro ourhouse_greet_long". Just before the error occurs, I get a debug
>> message "No language specified - Using [en]".
>>
>> If I substitute one of the Demo IVR macros for ourhouse_greet_long, it
>> will be executed with out error.
>>
>> The file containing macro is located in
>> /usr/local/freeswitch/conf/lang/en/ivr.
>>
>> So what have I done wrong? Any help appreciated. I can provide more
>> detail if needed.
>>
>> Thanks for your time.
>>
>> William.
>>
>>
>>
>>
>>
>>
>> _________________________________________________________________________
>> Professional FreeSWITCH Consulting Services:
>> consulting at freeswitch.org
>> http://www.freeswitchsolutions.com
>>
>> Official FreeSWITCH Sites
>> http://www.freeswitch.org
>> http://confluence.freeswitch.org
>> http://www.cluecon.com
>>
>> FreeSWITCH-users mailing list
>> FreeSWITCH-users at lists.freeswitch.org
>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>> http://www.freeswitch.org
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users
mailing list