Reputation: 203
I’m currently facing an issue of authentication when trying to send a basic GET request. The result I get from that attempt looks like this :
{“errors”:[{“code”:32,“message”:“Could not authenticate you.”}]}
I’m familiar with the fact that this error is rather common, but I find the problem intriguing, as it is still occurring after many hours trying to solve it. I used the app Postman (https://www.getpostman.com) to achieve this.
Here are the things I’ve tried to do :
Ensuring that the time and timezone of my machine are correctly set up
Ensuring that the timezone of my Twitter is correctly set up
Ensuring that the credentials are correct (identical to those from my Twitter app)
Adding some basic parameters to my request
Putting a link into the “callback_url” field in the app’s settings
Using another library - Tweetinvi (https://github.com/linvi/tweetinvi1)
Checking that the request URL was correct
All from those previous attempts have been vain. No solution that I found was able to resolve my problem.
Here’s a brief look at what my configuration in Postman looks like
Thank you for your help.
Upvotes: 3
Views: 3256
Reputation: 501
After running into some weird works/does not work auth issues** with Postman (v5.5 fat client and Chrome extension), I decided to try Insomnia Rest Client. Just to see if it's me or the REST Oauthv1 client.
** I got Postman working. After some time, without changing anything, it broke with:
{
"errors": [
{
"code": 89,
"message": "Invalid or expired token."
}
]
}
Basically the same errors others were reporting here. And by checking with Insomnia I found out that it must be Postman related.
brew cask install insomnia
on OSX gets you easily going (clients for Linux and Win also available). Then in the Insomnia client:
New Request
and give it a name (leave GET
as method for our test)OAuth1
in the Auth
tabhttps://api.twitter.com/1.1/search/tweets.json?q=%23golang
https://apps.twitter.com
) credentials
Consumer Key
Consumer Secret
Token
Token Secret
If this works, like in my tests, then there's something wrong with Postman and it's not your fault :)
Upvotes: 6