[Freeswitch-users] curl: parse XML response?

Michael Collins msc at freeswitch.org
Fri Feb 4 21:29:58 MSK 2011


Where are you doing the curl call? Just curious if this is happening inside
the dialplan or a script or what. FYI, I covered this in chapter 7 of the
FreeSWITCH book on how to use mod_curl from a Lua script and parse the
results. If you're just doing it from the dialplan then you probably need a
script, although you can try using the regex API. See
http://wiki.freeswitch.org/wiki/Mod_commands#From_the_Dialplan for tips on
how to call an API from within the dialplan.

-MC

On Thu, Feb 3, 2011 at 6:27 PM, james.royer at gmail.com <james.royer at gmail.com
> wrote:

> Hi All,
>
> I want to use mod_curl to query a web service and then extract information
> from the XML response.
>
> <response>
>   <value1>test</value1>
>   <value2>blah</value2>
> </response>
>
> I then want to use TTS to speak the values to the caller.
>
> How can I do this?
>
> I tried searches for "freeswitch parse xml" and other variations but all
> just talk about how FreeSWITCH parses config files.
>
> Thanks,
> James
>
> _______________________________________________
> 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/20110204/fb9fb216/attachment.html 


More information about the FreeSWITCH-users mailing list