[Freeswitch-users] correct method to play an audio file in a call originated from Freeswitch to a mobile number

Deepika Yadav deepikay at iiitd.ac.in
Fri Aug 26 07:58:15 MSD 2016


I have a use case using ESL, where I need to originate a call from from
Freeswitch to a mobile number and play a .wav after the recipient has
answered the call.

I am using following way to achieve this :

Step 1 . Issue esl command = ""originate " + gateway + "+91" + phone_number
+ " &park""
Step 2. command = ""uuid_transfer " + uuid + " 4441""

where dialplan 4441 has :

<extension name="ivr_demo">
      <condition field="destination_number" expression="^4441$">
   <action application="playback"
<action application="sleep" data="1000"/>

This works fine but sometimes, after answering of the call, listener does
not hear anything, file does not play.

If I do not use the park command and directly transfer to dialplan then the
 file starts playing immediately even if the user has not answered. How can
 I add a condition of answering in dialplan (<action application="answer"/>
does not work).

Is any other alternative to achieve this correctly.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20160826/4eb5f00f/attachment.html 

Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list