Sponsor: VoiceMeUp - Corporate & Wholesale VoIP Services

VoIP Mailing List Archives
Mailing list archives for the VoIP community
 SearchSearch 

[Freeswitch-users] JSON channel variable from Dialplan


 
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> freeSWITCH Users
View previous topic :: View next topic  
Author Message
grcamauer at gmail.com
Guest





PostPosted: Mon Apr 26, 2021 5:50 pm    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

Hi all,



Is it possible to set the value of a channel variable to a JSON formatted string?


I need to do something like this:


<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence and MY_VAR gets set to [\


How do I go about escaping double quotes in the dialplan?


--
Guillermo Ruiz Camauer
Back to top
s.safarov at gmail.com
Guest





PostPosted: Tue Apr 27, 2021 12:50 am    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

you create FreeSwitch mod using asr_set_json_text_params as example.
https://github.com/signalwire/freeswitch/blob/master/src/switch_ivr_async.c#L5306-L5331



On Tue, Apr 27, 2021 at 1:36 AM Guillermo Ruiz Camauer <grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:




Hi all,



Is it possible to set the value of a channel variable to a JSON formatted string?


I need to do something like this:


<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence and MY_VAR gets set to [\


How do I go about escaping double quotes in the dialplan?


--
Guillermo Ruiz Camauer



_________________________________________________________________________

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 (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 (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
Back to top
grcamauer at gmail.com
Guest





PostPosted: Tue Apr 27, 2021 3:20 pm    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

Thanks for the response, but actually all I needed to do was URL encode the JSON.


So the working version of
       <action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>
is


<action application="set" data="MY_VAR= %5B%5C%22Ford%5C%22%2C%20%5C%22Chevy%5C%22%5D"/>





Guillermo

On Tue, Apr 27, 2021 at 2:45 AM Sergey Safarov <s.safarov@gmail.com (s.safarov@gmail.com)> wrote:

Quote:
you create FreeSwitch mod using asr_set_json_text_params as example.
https://github.com/signalwire/freeswitch/blob/master/src/switch_ivr_async.c#L5306-L5331



On Tue, Apr 27, 2021 at 1:36 AM Guillermo Ruiz Camauer <grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:




Hi all,



Is it possible to set the value of a channel variable to a JSON formatted string?


I need to do something like this:


<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence and MY_VAR gets set to [\


How do I go about escaping double quotes in the dialplan?


--
Guillermo Ruiz Camauer



_________________________________________________________________________

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 (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 (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

_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer
Back to top
dujinfang at gmail.com
Guest





PostPosted: Tue May 04, 2021 8:28 pm    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

You can do that with standard xml CDATA syntax, find examples in the source tree https://github.com/signalwire/freeswitch/blob/master/conf/sbc/dialplan/default.xml

On Wed, Apr 28, 2021 at 4:16 AM Guillermo Ruiz Camauer <grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:
Thanks for the response, but actually all I needed to do was URL encode the JSON.


So the working version of
       <action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>
is


<action application="set" data="MY_VAR= %5B%5C%22Ford%5C%22%2C%20%5C%22Chevy%5C%22%5D"/>





Guillermo

On Tue, Apr 27, 2021 at 2:45 AM Sergey Safarov <s.safarov@gmail.com (s.safarov@gmail.com)> wrote:

Quote:
you create FreeSwitch mod using asr_set_json_text_params as example.
https://github.com/signalwire/freeswitch/blob/master/src/switch_ivr_async.c#L5306-L5331



On Tue, Apr 27, 2021 at 1:36 AM Guillermo Ruiz Camauer <grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:




Hi all,



Is it possible to set the value of a channel variable to a JSON formatted string?


I need to do something like this:


<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence and MY_VAR gets set to [\


How do I go about escaping double quotes in the dialplan?


--
Guillermo Ruiz Camauer



_________________________________________________________________________

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 (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 (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

_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer


_________________________________________________________________________

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 (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 (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



--
About: http://about.me/dujinfang
Blog: http://www.dujinfang.com
Proj:  http://www.freeswitch.org.cn
Back to top
grcamauer at gmail.com
Guest





PostPosted: Wed May 05, 2021 11:10 am    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

Yes, CDATA should work and also you can use &quot; for double quotes and &amp for single quotes.

Guillermo


On Tue, May 4, 2021 at 10:18 PM Seven Du <dujinfang@gmail.com (dujinfang@gmail.com)> wrote:

Quote:
You can do that with standard xml CDATA syntax, find examples in the source tree https://github.com/signalwire/freeswitch/blob/master/conf/sbc/dialplan/default.xml

On Wed, Apr 28, 2021 at 4:16 AM Guillermo Ruiz Camauer <grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:
Thanks for the response, but actually all I needed to do was URL encode the JSON.


So the working version of
       <action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>
is


<action application="set" data="MY_VAR= %5B%5C%22Ford%5C%22%2C%20%5C%22Chevy%5C%22%5D"/>





Guillermo

On Tue, Apr 27, 2021 at 2:45 AM Sergey Safarov <s.safarov@gmail.com (s.safarov@gmail.com)> wrote:

Quote:
you create FreeSwitch mod using asr_set_json_text_params as example.
https://github.com/signalwire/freeswitch/blob/master/src/switch_ivr_async.c#L5306-L5331



On Tue, Apr 27, 2021 at 1:36 AM Guillermo Ruiz Camauer <grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:




Hi all,



Is it possible to set the value of a channel variable to a JSON formatted string?


I need to do something like this:


<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence and MY_VAR gets set to [\


How do I go about escaping double quotes in the dialplan?


--
Guillermo Ruiz Camauer



_________________________________________________________________________

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 (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 (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

_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer


_________________________________________________________________________

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 (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 (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



--
About: http://about.me/dujinfang
Blog: http://www.dujinfang.com
Proj:  http://www.freeswitch.org.cn
_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer
Back to top
covici at ccs.covici.com
Guest





PostPosted: Wed May 05, 2021 1:50 pm    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

I thought &amp was for ampersand, is that not correct?

On Wed, 05 May 2021 11:38:48 -0400,
Guillermo Ruiz Camauer wrote:
Quote:

[1 <multipart/alternative (7bit)>]
[1.1 <text/plain; UTF-8 (7bit)>]
Yes, CDATA should work and also you can use &quot; for double quotes and
&amp for single quotes.

Guillermo

On Tue, May 4, 2021 at 10:18 PM Seven Du <dujinfang@gmail.com> wrote:

Quote:
You can do that with standard xml CDATA syntax, find examples in the
source tree
https://github.com/signalwire/freeswitch/blob/master/conf/sbc/dialplan/default.xml

On Wed, Apr 28, 2021 at 4:16 AM Guillermo Ruiz Camauer <
grcamauer@gmail.com> wrote:

Quote:
Thanks for the response, but actually all I needed to do was URL encode
the JSON.

So the working version of
<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>
is

<action application="set" data="MY_VAR=
%5B%5C%22Ford%5C%22%2C%20%5C%22Chevy%5C%22%5D"/>


Guillermo

On Tue, Apr 27, 2021 at 2:45 AM Sergey Safarov <s.safarov@gmail.com>
wrote:

Quote:
you create FreeSwitch mod using asr_set_json_text_params as example.

https://github.com/signalwire/freeswitch/blob/master/src/switch_ivr_async.c#L5306-L5331

On Tue, Apr 27, 2021 at 1:36 AM Guillermo Ruiz Camauer <
grcamauer@gmail.com> wrote:

Quote:


Hi all,


Is it possible to set the value of a channel variable to a JSON
formatted string?

I need to do something like this:

<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence
and MY_VAR gets set to [\

How do I go about escaping double quotes in the dialplan?

--
Guillermo Ruiz Camauer

_________________________________________________________________________

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

_________________________________________________________________________

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



--
Guillermo Ruiz Camauer
_________________________________________________________________________

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



--
About: http://about.me/dujinfang
Blog: http://www.dujinfang.com
Proj: http://www.freeswitch.org.cn
_________________________________________________________________________

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



--
Guillermo Ruiz Camauer
[1.2 <text/html; UTF-8 (quoted-printable)>]
[2 <text/plain; utf-8 (base64)>]
_________________________________________________________________________

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

--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?

John Covici wb2una
covici@ccs.covici.com

_________________________________________________________________________

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
Back to top
grcamauer at gmail.com
Guest





PostPosted: Wed May 05, 2021 4:17 pm    Post subject: [Freeswitch-users] JSON channel variable from Dialplan Reply with quote

Very much correct.  Single quote is &apos;

Guillermo


On Wed, May 5, 2021 at 3:44 PM John Covici <covici@ccs.covici.com (covici@ccs.covici.com)> wrote:

Quote:
I thought &amp was for ampersand, is that not correct?

On Wed, 05 May 2021 11:38:48 -0400,
Guillermo Ruiz Camauer wrote:
Quote:

[1  <multipart/alternative (7bit)>]
[1.1  <text/plain; UTF-8 (7bit)>]
Yes, CDATA should work and also you can use &quot; for double quotes and
&amp for single quotes.

Guillermo

On Tue, May 4, 2021 at 10:18 PM Seven Du <dujinfang@gmail.com (dujinfang@gmail.com)> wrote:

Quote:
You can do that with standard xml CDATA syntax, find examples in the
source tree
https://github.com/signalwire/freeswitch/blob/master/conf/sbc/dialplan/default.xml

On Wed, Apr 28, 2021 at 4:16 AM Guillermo Ruiz Camauer <
grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:
Thanks for the response, but actually all I needed to do was URL encode
the JSON.

So the working version of
        <action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>
is

<action application="set" data="MY_VAR=
%5B%5C%22Ford%5C%22%2C%20%5C%22Chevy%5C%22%5D"/>


Guillermo

On Tue, Apr 27, 2021 at 2:45 AM Sergey Safarov <s.safarov@gmail.com (s.safarov@gmail.com)>
wrote:

Quote:
you create FreeSwitch mod using asr_set_json_text_params as example.

https://github.com/signalwire/freeswitch/blob/master/src/switch_ivr_async.c#L5306-L5331

On Tue, Apr 27, 2021 at 1:36 AM Guillermo Ruiz Camauer <
grcamauer@gmail.com (grcamauer@gmail.com)> wrote:

Quote:


Hi all,


Is it possible to set the value of a channel variable to a JSON
formatted string?

I need to do something like this:

<action application="set" data="MY_VAR=[\"Ford\", \"Chevy\"]"/>

The problem seems to be that FS is not accepting the escape sequence
and MY_VAR gets set to [\

How do I go about escaping double quotes in the dialplan?

--
Guillermo Ruiz Camauer

_________________________________________________________________________

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 (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 (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

_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer
_________________________________________________________________________

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 (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 (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



--
About: http://about.me/dujinfang
Blog: http://www.dujinfang.com
Proj:  http://www.freeswitch.org.cn
_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer
[1.2  <text/html; UTF-8 (quoted-printable)>]
[2  <text/plain; utf-8 (base64)>]
_________________________________________________________________________

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 (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 (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

--
Your life is like a penny.  You're going to lose it.  The question is:
How do
you spend it?

         John Covici wb2una
         covici@ccs.covici.com (covici@ccs.covici.com)

_________________________________________________________________________

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 (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 (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



--
Guillermo Ruiz Camauer
Back to top
Display posts from previous:   
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> freeSWITCH Users All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

VoiceMeUp - Corporate & Wholesale VoIP Services