[Freeswitch-users] Perl ESL originate issue

Steven Ayre steveayre at gmail.com
Mon Sep 8 17:06:51 MSD 2014


It appears that variable substitution isn't done on the dialstring portion.

On 8 September 2014 13:48, David Villasmil <david.villasmil.work at gmail.com>
wrote:

> Hello Steven and thanks for your answer. I will try that, but why is that?
>
> On Mon, Sep 8, 2014 at 12:54 PM, Steven Ayre <steveayre at gmail.com> wrote:
>
>> my $uuid = $con->bgapi("eval", "originate
>> sofia/gateway/\${distributor(mylist)}/$destination &callcenter(myqueue)");
>>
>>
>> On 8 September 2014 11:54, Steven Ayre <steveayre at gmail.com> wrote:
>>
>>> You need to run it via the 'eval' API.
>>>
>>> On 8 September 2014 01:43, David Villasmil <
>>> david.villasmil.work at gmail.com> wrote:
>>>
>>>> Hello Guys,
>>>>
>>>> from perl i'm connecting to FS using FS' ESL library and issuing an
>>>> originate command which fails when i try to use ${distributor()}
>>>>
>>>> It seems FS' ESL Library or perl itself is changing "$" for "%", i get
>>>> an error:
>>>>
>>>> 2014-09-07 20:25:57.484946 [ERR] mod_sofia.c:4249 Invalid Gateway
>>>> '%{distributor(mylist)}'
>>>>
>>>> The command is actually:
>>>>
>>>> my $uuid = $con->bgapi("originate",
>>>> "sofia/gateway/\${distributor(mylist)}/$destination &callcenter(myqueue)");
>>>>
>>>> So i'm scaping $
>>>>
>>>> Has anyone experienced this?
>>>>
>>>> Thanks for you help!
>>>>
>>>> David
>>>>
>>>>
>>>> _________________________________________________________________________
>>>> 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
>>
>
>
> _________________________________________________________________________
> 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20140908/62c1bddc/attachment.html 


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