Take the 2-minute tour ×
Stack Apps is a question and answer site for apps, scripts, and development with the Stack Exchange API. It's 100% free, no registration required.

Now that the actual sites have updates for Questions and Inbox with WebSockets. Can we get access to these via the API? If they are stable enough for the sits, then surely they for the API?

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

You've got this all backwards.

Something being suitable for use on the sites is the first (not last) step in proving it's viable for inclusion in the API.

The difference is, if something isn't working out on the sites we can immediately change it. Websockets not working out? Go to long polling. Long poling also garbage? Just plain jane ajax'ing then.

Basically, what matters on the sites is the user experience not the technology used to create it.

The API, on the other hand, has to keep to a rigid contract. If websockets proved to be unacceptable we wouldn't have a recourse beyond breaking every single consumer. If in a few more months websockets are still chugging along, we'll start thinking about using them in the API.


As an aside, websockets aren't nearly as stable as you think on the sites at the moment. We've disabled them multiple times in the last few weeks, and have major caveats around how they're used (primarily, they're push only; you can't communicate with the server).

share|improve this answer
    
Have you tried Server-Sent events? en.wikipedia.org/wiki/Server-sent_events –  Adam May 4 '12 at 17:45
add comment

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .