400 "{"errors":[{"message":"Bad Authentication data","code":215}]}


#41

I’ve just started getting this same error ({“errors”:[{“message”:“Bad Authentication data”,“code”:215}]}),

It started on the 21st March just after the API move from 1 to 1.1? I’m using the Abraham library to sign in and the Matt Harris library to tweet an image. It was working fine just before the switch from API 1 to 1.1 and both are still working fine by themselves (hard coded token and secret for Update_with_image)… but when I log in as a user and try to tweet an image the error pops up?

Any help would be appreciated.


#42

I think the problem stems from the certificate file that needs to be in the path of the executing script. I have two web pages that use the same functions in another script and one worked while the other didn’t. When I moved the include directive to the top of the script file, it worked. I am using tmhOAuth.php and tmhUtilities.php using version 1. The cacert.pem file is required for authentication and without it, you end up with ambiguous errors.


#43

https://api.twitter.com/1.1/search/tweets.json has same issue?


#44

I am also getting the same issue with https://api.twitter.com/1.1/search/tweets.json using a bearer token from app-only auth. Can anyone show a working example of the 1.1 search using app-only auth? I have mine version coded in Java


#45

how to use OAuth, I have token, verifier etc, and I tried to use these in url parameters, and in request header too, but still having bad authentication data since last weekend,
Kindly let me know the proper format where and how to send the required credentials, as this link (http://stackoverflow.com/questions/14095272/twitter-api-1-1-gives-error-code-32) says something is needed to be sorted, I tried header parameter sorted too, but still same error.
I am requesting the timeline in Android http client request


#46

have you got it fixed ??


#47

@episod, need guide


#48

To get follower list I used this https://api.twitter.com/1.1/followers/list.json?cursor=-1&screen_name=cf_android&skip_status=true&include_user_entities=false but everytime I am facing Bad Authentication Data Code:215


#49

auth = tweepy.OAuthHandler(consumer_token,consumer_secret)
auth.set_access_token(access_token,access_secret)

api  = tweepy.API(auth)
for status in tweepy.Cursor(api.user_timeline, id=screen_name).items(2): 
    print status.text+'\n'

I just used the above to get user’s timeline with ‘screen_name’.


#50

This stackoverflow answer fixed the issue for me, Zend Framework (PHP): http://stackoverflow.com/a/16002174/16783


#51

Same problem for me also :frowning:


#52

I was able to solve the 400 error by sorting the oauth_xx parameters in the Authorization header alphabetically and I also removed the double quotes around the parameter names. I just looked at the differences with the request the OAuth tool generated at the dev.twitter.com web site and managed to figure it out.

The header should look like:

Authorization: OAuth oauth_consumer_key="xxx", oauth_nonce="xxx", oauth_signature="xxx", oauth_signature_method="HMAC-SHA1", oauth_timestamp="xxx", oauth_token="xxx", oauth_version="1.0"

#53

i am facing the same problem for
https://api.twitter.com/1.1/search/tweets.json?q=%23freebandnames&since_id=24012619984051000&max_id=250126199840518145&result_type=mixed&count=4
this url

and returning this result
{“errors”:[{“message”:“Bad Authentication data”,“code”:215}]}

please if some one got the solution please post over here. thanks in advance


#54

Hi Taylor,

Do you mind pasting an example of how the URL for searching will look like with all the Oath parameters needed? I think that will help a lot!

Thank you!


#56

hi, i am done with the twitter search API in january late, but due to the changes in API v1.1 my code is not working right now.
i am using the consumer key,secret key access key and access secret key and using the URL as given below:
"https://api.twitter.com/1.1/search/tweets.json?q=".$srchterm."&since_id=24012619984051000&max_id=250126199840518145&result_type=mixed&count=4"
but i didn’t get the right answer. Can you please help me out.
thanx in advance.


#57

Was this resolved, I am getting the same payload

{“errors”=>[{“message”=>“Bad Authentication data”, “code”=>215}]}


#58

hi guys,
new to twitter dev.
trying to use https://api.twitter.com/1.1/statuses/mentions_timeline.json?count=2&since_id=14927799 in the browser.
getting error : {“errors”:[{“message”:“Bad Authentication data”,“code”:215}]}

Can anyone help ?

Regards,
Shagun


#59

I am facing the same issue can u help me???


#60

I am facing the same issue…I am using PHP…can anyone help me???


#61

Hrm. Having the same problem. Can’t even get Twitter’s example code to work. What did I do wrong? Thank you in advance for the help!