REST API V1.1 search functionality giving (215 Bad Authentication) data error


Am using twitter REST API V1.1 like this
HTTParty.get(“",{:headers=>{“content-type”=>“application/json”,“accept”=>"application json”},:body=>{}})
but it giving error (215, Bad Authentication data)
Can any one give the solution for this?

but am using user/show API like same as above i used,It working fine.


API v1.1 endpoints require OAuth authentication – are you leveraging OAuth in your request to the 1.1/users/search API?


I don’t know how to authenticate using OAuth using rails, can you give me some guidance. do you have any sample ruby code for this.
i tried this url for oauth authentication & i registered one application in twitter, using that consumer_key and app_id i tried this.
but i cant get the solution.


Depending on how you like to code, there’s an OAuth gem for Ruby that’s pretty decent. It’s the simplest way to interact with the API and process responses yourself. If you prefer a more object-oriented approach, check out the “twitter” gem on github.


We have a native iPhone app in which we are using v1 of Twitter Search API. We would like to migrate to using V1.1 Search API but not entirely sure how to authenticate using OAuth. The Nonce and Timestamp parameters are confusing.

We only require READ-ONLY access to tweets. Any guidance or sample code would be helpful.


Yeah, I’m having the same issue with 1.1, but it’s weird. It works with say “lebron”, but if I search for “#lebron”, then I get the above error. I am mapping the # to %23.


I’m trying to migrate my android app from v1 to v1.1. Not sure how I can use oauth for twitter search queries. If there’s an existing reference, please point me towards it.



while using the REST API v 1.1 for the user details

GET account/verify_credentials

getting the bad authentication data 215 .

so before getting details i already had the access token and token secret and request with the simple process of url request in android.As new to android and most with the twitter api not getting what to do?


With Twitter API ME how to get the profile image or avatar image.