Calling a destination and playing a pre-recorded message.
Hi. I have a FreeSWITCH system up and running and I can make calls from one device to another which is fine. What I would now like to do is integrate it with another system so that when certain events occur in this other system, it dials one or more destinations and plays a pre-recorded message before hanging up. Can the playing of the sound file be hooked into a custom dialplan? I ask because a little experimentation has revealed that the dialplan is processed on the inbound channel (which seems entirely reasonable) which means that using playback in the dialplan results in audio sent to the caller, rather than the called. If this can't be achieved via the dialplan, does this mean that I need to create a specific client that can call a destination and somehow pipe sound into the input channel, rather than taking it from whatever input device might be available? Thanks for any assistance offered. Paul Sent from my Windows 10 device
It is absolutely feasible to implement your use case via the dialplan; check the first example here: https://freeswitch.org/confluence/display/FREESWITCH/Originate+Example If the use case is as simple as placing an outbound call, playing back some media and then hanging up, you could implement is as: originate {ignore_early_media=true,originate_timeout=60}sofia/gateway/name/number &playback(message) More information here: https://freeswitch.org/confluence/display/FREESWITCH/mod_commands#mod_comman... On Mon, 18 Nov 2019 at 14:33, Paul Mateer <Paul.Mateer@outlook.com> wrote:
Hi. I have a FreeSWITCH system up and running and I can make calls from one device to another which is fine.
What I would now like to do is integrate it with another system so that when certain events occur in this other system, it dials one or more destinations and plays a pre-recorded message before hanging up.
Can the playing of the sound file be hooked into a custom dialplan? I ask because a little experimentation has revealed that the dialplan is processed on the inbound channel (which seems entirely reasonable) which means that using playback in the dialplan results in audio sent to the caller, rather than the called.
If this can't be achieved via the dialplan, does this mean that I need to create a specific client that can call a destination and somehow pipe sound into the input channel, rather than taking it from whatever input device might be available?
Thanks for any assistance offered.
Paul
Sent from my Windows 10 device
_________________________________________________________________________
The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform.
Join our online community to chat in real time https://signalwire.community
Professional FreeSWITCH Services sales@freeswitch.com https://freeswitch.com
Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com
-- Best Regards, Ciprian Dosoftei The information transmitted is intended only for the addressee and may contain privileged and/or confidential material. If you are not the intended recipient, kindly contact the sender and delete the message. Any disclosure, distribution or copying of this message is strictly prohibited without the expressed permission of the sender.
I must be doing something wrong then, because I run a command of the form originate <url> XML public &playback(c:/temp/test.wav) and the call goes through, but I don't hear anything at the called end. I do see an entry in the log like: Transfer sofia/internal/gateway@ip:port to public[xml@&playback(c:/temp/test.wav)] Which presumably was caused by the playback command, but I don't know if this is to be expected, and i it is whether the details are correct. Paul Sent from my Windows 10 device From: Ciprian Dosoftei<mailto:ciprian.dosoftei@gmail.com> Sent: 18 November 2019 20:01 To: FreeSWITCH Users Help<mailto:freeswitch-users@lists.freeswitch.org> Subject: Re: [Freeswitch-users] Calling a destination and playing a pre-recorded message. It is absolutely feasible to implement your use case via the dialplan; check the first example here: https://freeswitch.org/confluence/display/FREESWITCH/Originate+Example If the use case is as simple as placing an outbound call, playing back some media and then hanging up, you could implement is as: originate {ignore_early_media=true,originate_timeout=60}sofia/gateway/name/number &playback(message) More information here: https://freeswitch.org/confluence/display/FREESWITCH/mod_commands#mod_comman... On Mon, 18 Nov 2019 at 14:33, Paul Mateer <Paul.Mateer@outlook.com<mailto:Paul.Mateer@outlook.com>> wrote: Hi. I have a FreeSWITCH system up and running and I can make calls from one device to another which is fine. What I would now like to do is integrate it with another system so that when certain events occur in this other system, it dials one or more destinations and plays a pre-recorded message before hanging up. Can the playing of the sound file be hooked into a custom dialplan? I ask because a little experimentation has revealed that the dialplan is processed on the inbound channel (which seems entirely reasonable) which means that using playback in the dialplan results in audio sent to the caller, rather than the called. If this can't be achieved via the dialplan, does this mean that I need to create a specific client that can call a destination and somehow pipe sound into the input channel, rather than taking it from whatever input device might be available? Thanks for any assistance offered. Paul Sent from my Windows 10 device _________________________________________________________________________ The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform. Join our online community to chat in real time https://signalwire.community Professional FreeSWITCH Services sales@freeswitch.com<mailto:sales@freeswitch.com> https://freeswitch.com Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com -- Best Regards, Ciprian Dosoftei The information transmitted is intended only for the addressee and may contain privileged and/or confidential material. If you are not the intended recipient, kindly contact the sender and delete the message. Any disclosure, distribution or copying of this message is strictly prohibited without the expressed permission of the sender.
Hello, You need to put the file you want to play in a directory fs can access and not pass anything like "c:\". I store them (i only need them temporarily) in /tmp/ I.e.: bgapi originate {origination_caller_id_number=[CALLER-ID}sofia/gateway/nexvortex/[SOME-DESTINATION-NUMBER] &playback(/tmp/test.wav) Note the dialstring. Hope that helps Regards, David Villasmil email: david.villasmil.work@gmail.com phone: +34669448337 On Tue, Nov 19, 2019 at 10:36 AM Paul Mateer <Paul.Mateer@outlook.com> wrote:
I must be doing something wrong then, because I run a command of the form
originate <url> XML public &playback(c:/temp/test.wav)
and the call goes through, but I don't hear anything at the called end. I do see an entry in the log like:
Transfer sofia/internal/gateway@ip:port to public[xml@ &playback(c:/temp/test.wav)]
Which presumably was caused by the playback command, but I don't know if this is to be expected, and i it is whether the details are correct.
Paul
Sent from my Windows 10 device
*From: *Ciprian Dosoftei <ciprian.dosoftei@gmail.com> *Sent: *18 November 2019 20:01 *To: *FreeSWITCH Users Help <freeswitch-users@lists.freeswitch.org> *Subject: *Re: [Freeswitch-users] Calling a destination and playing a pre-recorded message.
It is absolutely feasible to implement your use case via the dialplan; check the first example here:
https://freeswitch.org/confluence/display/FREESWITCH/Originate+Example
If the use case is as simple as placing an outbound call, playing back some media and then hanging up, you could implement is as:
originate {ignore_early_media=true,originate_timeout=60}sofia/gateway/name/number &playback(message)
More information here: https://freeswitch.org/confluence/display/FREESWITCH/mod_commands#mod_comman...
On Mon, 18 Nov 2019 at 14:33, Paul Mateer <Paul.Mateer@outlook.com> wrote:
Hi. I have a FreeSWITCH system up and running and I can make calls from one device to another which is fine.
What I would now like to do is integrate it with another system so that when certain events occur in this other system, it dials one or more destinations and plays a pre-recorded message before hanging up.
Can the playing of the sound file be hooked into a custom dialplan? I ask because a little experimentation has revealed that the dialplan is processed on the inbound channel (which seems entirely reasonable) which means that using playback in the dialplan results in audio sent to the caller, rather than the called.
If this can't be achieved via the dialplan, does this mean that I need to create a specific client that can call a destination and somehow pipe sound into the input channel, rather than taking it from whatever input device might be available?
Thanks for any assistance offered.
Paul
Sent from my Windows 10 device
_________________________________________________________________________
The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform.
Join our online community to chat in real time https://signalwire.community
Professional FreeSWITCH Services sales@freeswitch.com https://freeswitch.com
Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com
-- Best Regards, Ciprian Dosoftei
The information transmitted is intended only for the addressee and may contain privileged and/or confidential material. If you are not the intended recipient, kindly contact the sender and delete the message.
Any disclosure, distribution or copying of this message is strictly prohibited without the expressed permission of the sender. _________________________________________________________________________
The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform.
Join our online community to chat in real time https://signalwire.community
Professional FreeSWITCH Services sales@freeswitch.com https://freeswitch.com
Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com
BTW, yes you can use as a dialstring something like bgapi originate sofia/internal/[DEST-NUMBER]@IP:PORT &playback(/tmp/test.wav) Regards, David Villasmil email: david.villasmil.work@gmail.com phone: +34669448337 On Tue, Nov 19, 2019 at 12:07 PM David Villasmil < david.villasmil.work@gmail.com> wrote:
Hello,
You need to put the file you want to play in a directory fs can access and not pass anything like "c:\". I store them (i only need them temporarily) in /tmp/
I.e.:
bgapi originate {origination_caller_id_number=[CALLER-ID}sofia/gateway/nexvortex/[SOME-DESTINATION-NUMBER] &playback(/tmp/test.wav)
Note the dialstring.
Hope that helps
Regards,
David Villasmil email: david.villasmil.work@gmail.com phone: +34669448337
On Tue, Nov 19, 2019 at 10:36 AM Paul Mateer <Paul.Mateer@outlook.com> wrote:
I must be doing something wrong then, because I run a command of the form
originate <url> XML public &playback(c:/temp/test.wav)
and the call goes through, but I don't hear anything at the called end. I do see an entry in the log like:
Transfer sofia/internal/gateway@ip:port to public[xml@ &playback(c:/temp/test.wav)]
Which presumably was caused by the playback command, but I don't know if this is to be expected, and i it is whether the details are correct.
Paul
Sent from my Windows 10 device
*From: *Ciprian Dosoftei <ciprian.dosoftei@gmail.com> *Sent: *18 November 2019 20:01 *To: *FreeSWITCH Users Help <freeswitch-users@lists.freeswitch.org> *Subject: *Re: [Freeswitch-users] Calling a destination and playing a pre-recorded message.
It is absolutely feasible to implement your use case via the dialplan; check the first example here:
https://freeswitch.org/confluence/display/FREESWITCH/Originate+Example
If the use case is as simple as placing an outbound call, playing back some media and then hanging up, you could implement is as:
originate {ignore_early_media=true,originate_timeout=60}sofia/gateway/name/number &playback(message)
More information here: https://freeswitch.org/confluence/display/FREESWITCH/mod_commands#mod_comman...
On Mon, 18 Nov 2019 at 14:33, Paul Mateer <Paul.Mateer@outlook.com> wrote:
Hi. I have a FreeSWITCH system up and running and I can make calls from one device to another which is fine.
What I would now like to do is integrate it with another system so that when certain events occur in this other system, it dials one or more destinations and plays a pre-recorded message before hanging up.
Can the playing of the sound file be hooked into a custom dialplan? I ask because a little experimentation has revealed that the dialplan is processed on the inbound channel (which seems entirely reasonable) which means that using playback in the dialplan results in audio sent to the caller, rather than the called.
If this can't be achieved via the dialplan, does this mean that I need to create a specific client that can call a destination and somehow pipe sound into the input channel, rather than taking it from whatever input device might be available?
Thanks for any assistance offered.
Paul
Sent from my Windows 10 device
_________________________________________________________________________
The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform.
Join our online community to chat in real time https://signalwire.community
Professional FreeSWITCH Services sales@freeswitch.com https://freeswitch.com
Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com
-- Best Regards, Ciprian Dosoftei
The information transmitted is intended only for the addressee and may contain privileged and/or confidential material. If you are not the intended recipient, kindly contact the sender and delete the message.
Any disclosure, distribution or copying of this message is strictly prohibited without the expressed permission of the sender. _________________________________________________________________________
The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform.
Join our online community to chat in real time https://signalwire.community
Professional FreeSWITCH Services sales@freeswitch.com https://freeswitch.com
Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com
FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com
Great. Finally got things working. Thanks for the tip on keeping the sound files within the FreeSWITCH hierarchy. Paul Sent from my Windows 10 device From: David Villasmil<mailto:david.villasmil.work@gmail.com> Sent: 19 November 2019 13:00 To: FreeSWITCH Users Help<mailto:freeswitch-users@lists.freeswitch.org> Subject: Re: [Freeswitch-users] Calling a destination and playing a pre-recorded message. Hello, You need to put the file you want to play in a directory fs can access and not pass anything like "c:\". I store them (i only need them temporarily) in /tmp/ I.e.: bgapi originate {origination_caller_id_number=[CALLER-ID}sofia/gateway/nexvortex/[SOME-DESTINATION-NUMBER] &playback(/tmp/test.wav) Note the dialstring. Hope that helps Regards, David Villasmil email: david.villasmil.work@gmail.com<mailto:david.villasmil.work@gmail.com> phone: +34669448337 On Tue, Nov 19, 2019 at 10:36 AM Paul Mateer <Paul.Mateer@outlook.com<mailto:Paul.Mateer@outlook.com>> wrote: I must be doing something wrong then, because I run a command of the form originate <url> XML public &playback(c:/temp/test.wav) and the call goes through, but I don't hear anything at the called end. I do see an entry in the log like: Transfer sofia/internal/gateway@ip:port to public[xml@&playback(c:/temp/test.wav)] Which presumably was caused by the playback command, but I don't know if this is to be expected, and i it is whether the details are correct. Paul Sent from my Windows 10 device From: Ciprian Dosoftei<mailto:ciprian.dosoftei@gmail.com> Sent: 18 November 2019 20:01 To: FreeSWITCH Users Help<mailto:freeswitch-users@lists.freeswitch.org> Subject: Re: [Freeswitch-users] Calling a destination and playing a pre-recorded message. It is absolutely feasible to implement your use case via the dialplan; check the first example here: https://freeswitch.org/confluence/display/FREESWITCH/Originate+Example If the use case is as simple as placing an outbound call, playing back some media and then hanging up, you could implement is as: originate {ignore_early_media=true,originate_timeout=60}sofia/gateway/name/number &playback(message) More information here: https://freeswitch.org/confluence/display/FREESWITCH/mod_commands#mod_comman... On Mon, 18 Nov 2019 at 14:33, Paul Mateer <Paul.Mateer@outlook.com<mailto:Paul.Mateer@outlook.com>> wrote: Hi. I have a FreeSWITCH system up and running and I can make calls from one device to another which is fine. What I would now like to do is integrate it with another system so that when certain events occur in this other system, it dials one or more destinations and plays a pre-recorded message before hanging up. Can the playing of the sound file be hooked into a custom dialplan? I ask because a little experimentation has revealed that the dialplan is processed on the inbound channel (which seems entirely reasonable) which means that using playback in the dialplan results in audio sent to the caller, rather than the called. If this can't be achieved via the dialplan, does this mean that I need to create a specific client that can call a destination and somehow pipe sound into the input channel, rather than taking it from whatever input device might be available? Thanks for any assistance offered. Paul Sent from my Windows 10 device _________________________________________________________________________ The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform. Join our online community to chat in real time https://signalwire.community Professional FreeSWITCH Services sales@freeswitch.com<mailto:sales@freeswitch.com> https://freeswitch.com Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com -- Best Regards, Ciprian Dosoftei The information transmitted is intended only for the addressee and may contain privileged and/or confidential material. If you are not the intended recipient, kindly contact the sender and delete the message. Any disclosure, distribution or copying of this message is strictly prohibited without the expressed permission of the sender. _________________________________________________________________________ The FreeSWITCH project is sponsored by SignalWire https://signalwire.com Enhance your FreeSWITCH install with disruptive priced SMS and PSTN services. Build your next product on our scalable cloud platform. Join our online community to chat in real time https://signalwire.community Professional FreeSWITCH Services sales@freeswitch.com<mailto:sales@freeswitch.com> https://freeswitch.com Official FreeSWITCH Sites https://freeswitch.com/oss https://freeswitch.org/confluence https://cluecon.com FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users https://freeswitch.com
participants (3)
-
Ciprian Dosoftei
-
David Villasmil
-
Paul Mateer