User Streams API and Policy Changes

20 views
Skip to first unread message

John Kalucki

unread,
Sep 13, 2010, 5:13:43 PM9/13/10
to twitter-ap...@googlegroups.com
The following changes must be reflected in all User Streams clients:


HTTP and Basic Auth removed
====
HTTP and Basic Auth are now unsupported on User Streams endpoints. All other Twitter APIs are unaffected by this change. No end-users should be affected by this change as all current User Streams application versions use HTTPS and OAuth. 


Version in User Agent
=====
The User-Agent HTTP header must be set to include the application's version. This will be critical in diagnosing issues with your client. If your environment precludes setting this the User-Agent field, you must then set an X-User-Agent field.


Connection Limits and Error Code
=====
Each Twitter account will soon be limited to only a few simultaneous User Streams connections per OAuth application. Once the per-application limit is exceeded, the account's oldest connection from that OAuth application will be terminated. An account logging in from too many instances of the same OAuth application will continuously cycle their connections as the applications reconnect and throw each other off the service. Note that each application has its own allocation, so that logging in from App_1 doesn't affect your App_2 allocation, and visa versa, but running too many copies of either App_1 or App_2 will cause problems. 

Clients must be prepared to receive a 420 error code that indicates that the account has been logging in too often. This code will be the indication that the account has exceeded the per-account-per-application connection limit described above. This situation should be raised to the user, as they have been automatically and temporarily banned from User Streams for an excessive login rate. The user should be advised to shut down extra copies of the application, perhaps instances running on another device, to restore streaming access.


-John Kalucki
Twitter, Inc.



Reply all
Reply to author
Forward
0 new messages