Further investigation shows then regardless header “X-Warning” with value “Invalid OAuth credentials detected”, Twitter API returns correct results. For example for https://api.twitter.com/1.1/followers/ids.json API end point:
ad@MacBook-Pro-Andrew:~/Projects/crm/nimble-all/server$ ./bin/python spikes/twitter_sample_script.py
{
“Content-Length”: “279”,
“Vary”: “Accept-Encoding”,
“Last-Modified”: “Thu, 15 Nov 2012 17:15:06 GMT”,
“Etag”: ““3c5ea6226d18c1609b9f801cfa175cad””,
“X-Rate-Limit-Limit”: “15”,
“X-Frame-Options”: “SAMEORIGIN”,
“Status”: “200 OK”,
“X-Warning”: “Invalid OAuth credentials detected”,
“Expires”: “Tue, 31 Mar 1981 05:00:00 GMT”,
“X-Runtime”: “0.03477”,
“Pragma”: “no-cache”,
“Date”: “Thu, 15 Nov 2012 17:15:06 GMT”,
“X-Mid”: “c2c44b9f635023a75baa9a752251243b0a50a295”,
“Server”: “tfe”,
“X-Rate-Limit-Reset”: “1353000583”,
“X-Rate-Limit-Remaining”: “14”,
“X-Transaction”: “2d4d57e08d65c51c”,
“Content-Encoding”: “gzip”,
“X-Access-Level”: “read-write-directmessages”,
“X-Transaction-Mask”: “a6183ffa5f8ca943ff1b53b5644ef11431c40d6d”,
“Cache-Control”: “no-cache, no-store, must-revalidate, pre-check=0, post-check=0”,
“Content-Type”: “application/json; charset=utf-8”
}
###########
{“previous_cursor”:0,“next_cursor_str”:“0”,“previous_cursor_str”:“0”,“ids”:[222610802,878466810,201719565,577263351,532089799,541409089,41996168,21012772,89555813,263162302,14474236,6307,288828607,16142725,308740049,15457017,286154032,149031304,169456479,198261984,252197355,14919708,59760114,39230470,49620664,11490062,84610398,2155551,126296626,19647074,76146772,26996686,16045315,194140350,3931941,20046595,101151091,99877670,92418872,20903135],“next_cursor”:0}
###########
REQUEST FAILED!
ad@MacBook-Pro-Andrew:~/Projects/crm/nimble-all/server$
So only problem Twitter API set incorrect X-Warning header