Cannot figure out code 215 Bad Authentication data


#1

I have been attempting unsuccessfully to use OAuth to connect to twitter and get search results using the /1.1/search/tweets method.

I am writing the http request in C# using logic found at http://cropperplugins.codeplex.com/SourceControl/changeset/view/65377#1710422.

I have used this very logic for the Vimeo Upload API to remotely upload videos to Vimeo and it works flawless without issues. But I am running into issues for the twitter search query and I just can’t figure out why. I’ve been looking through these forums and other places and no things seem to work for me.

This is my request:

GET /1.1/search/tweets.json?q=housing&count=2 HTTP/1.1
Host: api.twitter.com
Accept: */*
Authorization: OAuth
oauth_consumer_key="Wfzt2bgMzpTonowvakvg",
oauth_nonce="a9f250c2101ab2f38476ac658bab5738",
oauth_signature="7AUjOC0EDNNDoRy8g%2FiTB15Eytk%3D", 
oauth_signature_method="HMAC-SHA1", 
oauth_timestamp="1357836951",
oauth_token="993733860-0ypfqyIWbaBlqXFKkMkBMPikZ0VvD9B3UDMn1Jmc",
 oauth_version="1.0"

Response:
HTTP/1.1 400 Bad Request
Content-Type: application/json; charset=utf-8
Content-Length: 61
Date: Thu, 10 Jan 2013 16:55:51 UTC
Server: tfe

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

My app is a web app and I added a generic callback url in the settings. That didn’t work. I checked if the time stamps were out of sync, but they seem to be in sync. Is there any header in the http request that I am missing? I am using the consumer secret and token secret that is provided on my app details page. Also, this is the only request I am making. There are no other requests (authentication, request_token) that I am making. Should I though?

Any pointers would be greatly appreciated.


#2

I’m having the same issue - also in C#. Did you ever get this resolved?

Thanks,

Joe