<div dir="ltr">Joshua,<div><br></div><div>Thanks, I am really looking forward to the new REST API support. I know it will take a while to get all the pieces in place.</div><div><br></div><div>I don't know what the Digium vision is for the REST API, but what I would like to see is a simple WebSocket connection that can receive granular events for all the call activity on the Asterisk server. This would allow a Node.js application to know everything that is happening so it could support UC web apps that also connect to the Node.js server.</div>
<div><br></div><div>If the ARI has enough granularity to let the Node.js application make real-time call control decisions and manage call progress and features, then the Asterisk servers(s) could be used as SIP and media edge devices with third party call control running on the Node.js platform.</div>
<div><br></div><div>Jim</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Sep 12, 2013 at 10:07 AM, Joshua Colp <span dir="ltr"><<a href="mailto:jcolp@digium.com" target="_blank">jcolp@digium.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Jim Fathman wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hello,<br>
</blockquote>
<br>
Bonjour!<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I am experimenting with Asterisk 12.0.0 alpha1. I have a couple of SIP<br>
phones working. Good. I can retrieve data using curl to interact with<br>
the new Asterisk REST API (ARI). Good.<br>
<br>
Now I want to use the new ARI events API, which requires a WebSocket<br>
connection. I am using Node.js for the client, and have a stable<br>
connection to ARI events on the Asterisk 12 server.<br>
<br>
What I hope for is that my Node.js client will receive call related<br>
events in JSON format messages as call activity occurs on the Asterisk<br>
server. But I don't know how to request this information via the API.<br>
<br>
Do I need to specify something in the query string used for the initial<br>
WebSocket connection? Or do I need to send some kind of event<br>
subscription messages within the WebSocket once connected?<br>
</blockquote>
<br></div>
David Lee (ARI man supreme) is currently working on an issue [1] which covers support for subscribing for this information for delivery over the WebSocket connection in a branch [2]. I'd expect this to be integrated into 12 within a few weeks. I believe it should cover what you want to do.<br>
<br>
[1] <a href="https://issues.asterisk.org/jira/browse/ASTERISK-22451" target="_blank">https://issues.asterisk.org/<u></u>jira/browse/ASTERISK-22451</a><br>
[2] <a href="http://svn.digium.com/svn/asterisk/team/dlee/ASTERISK-22451-ari-subscribe/" target="_blank">http://svn.digium.com/svn/<u></u>asterisk/team/dlee/ASTERISK-<u></u>22451-ari-subscribe/</a><br>
<br>
Cheers,<br>
<br>
-- <br>
Joshua Colp<br>
Digium, Inc. | Senior Software Developer<br>
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA<br>
Check us out at: <a href="http://www.digium.com" target="_blank">www.digium.com</a> & <a href="http://www.asterisk.org" target="_blank">www.asterisk.org</a><br>
<br>
--<br>
______________________________<u></u>______________________________<u></u>_________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/<u></u>mailman/listinfo/asterisk-<u></u>users</a><br>
</blockquote></div><br></div>