<div dir="ltr">Hi David,<div>Apparently freeswitch&#39;s mod_verto offers a RESTful JSON interface to FS.</div><div>Please check out this page: <a href="https://freeswitch.org/confluence/display/FREESWITCH/Restful">https://freeswitch.org/confluence/display/FREESWITCH/Restful</a></div><div>Thanks</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 26, 2015 at 4:58 PM, David McNab <span dir="ltr">&lt;<a href="mailto:davidmcnabnz@gmail.com" target="_blank">davidmcnabnz@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi there,<br><br></div>How do you do API calls in JSON? Or, how do I get a list of all the API calls which can receive JSON parameters and return JSON return values?<br><br></div>For example, in the console, I tried &#39;show calls&#39;, and got a list of calls. I did the same call from via XML-RPC from a python script, and got a single string back, containing what would have been output to the console. But when I tried, from the console:<br><br></div><div><span style="font-family:monospace,monospace"><b>json {&quot;command&quot;:&quot;show calls&quot;, &quot;format&quot;:&quot;pretty&quot;, &quot;data&quot;:{}}</b></span><br></div><div><br>I got an invalid response.<br><br></div><div>I also tried:<br><br><b>json {&quot;command&quot;:&quot;show&quot;, &quot;format&quot;:&quot;pretty&quot;, &quot;data&quot;:&quot;calls&quot;}</b><br><br></div><div>but got similar.<br><br></div><div>Is there a general sceme for invoking all the console API commands (and receiving responses) in JSON format?<br><br></div><div>If not, I guess I need to write some parsers to process each command&#39;s output string.<br><br></div><div>Cheers<span class="HOEnZb"><font color="#888888"><br></font></span></div><span class="HOEnZb"><font color="#888888"><div>David<br><br></div></font></span></div>
<br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br></blockquote></div><br></div>