401 when connecting to /2b/site.json


Hi all,

I am quite sure I have already posted about this issue though I don’t seem to be abe to find that thread anymore. So just in case, sorry for dups.

I get this error when connecting to streaming API at /2b/site.json?with=followings&follow=20937471

The response I receive is:

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Error 401 Unauthorized</title>
<h2>HTTP ERROR: 401</h2>
<p>Problem accessing \'/2b/site.json?with=followings&amp;follow=20937471\'. Reason:
<pre>    Unauthorized</pre>
[...lots of newlines...] 

And the headers are:

{ 'content-type': 'text/html',
  'www-authenticate': 'Basic realm="Firehose"',
  'cache-control': 'must-revalidate,no-cache,no-store',
  'content-length': '1267',
  connection: 'close' }

It was working for ages but then suddenly stopped out of the blue. I can still use my oAuth credentials for normal API calls, which work fine.

Any idea what could be causing it?

My API key is rjfl7zomtBvH4kQgyd3knw



Bump. Anyone experienced this?


Make sure that when you’re connecting you’re doing so using the access token representing your identity – the account that owns the application must be the user context when connecting to Site Streams. Verify that using the same credentials you can both issue a request to account/verify_credentials on the REST API as well as to Site Streams on the streaming API – I recommend using twurl on the command line to accomplish this. Also, watch out for any clock drift you may have had – the streaming API’s OAuth implementation is going to be stricter than the REST API’s.


YOU ARE AWESOME @episod!!!

running "ntpdate ntp.ubuntu.com"just nailed it!

Thanks heaps!!!