Hi.
I’m using api GET call - https://api.twitter.com/1.1/account/verify_credentials.json for validating on server side the token i got from my application, but i’m getting the response - {“errors”:[{“code”:215,“message”:“Bad Authentication data.”}]}
What am i doing wrong? i used the URL parameter key of “oauth_token” (for example : https://api.twitter.com/1.1/account/verify_credentials.json?oauth_token=)
Thanks in advance!
Is adding a oauth_token param all you are doing? There is a lot more to signing OAuth 1 requests than just that. I recommend you find and established library in your language of choice and let it handle signing requests.
oauth_token
Ok, but isn’t there a convinient way to validate an access token without an authenticated rest api call? All i need is to check if the token is not revoked
That’s you you know the access token has not been revoked. You make an authenticated request with it. If the request succeeds the access token is still valid.