DrDee
DrDee

Reputation: 3609

Exchange Oauth Request Token for Access Token fails Google API

I am having trouble exchanging my Oauth request token for an Access Token. My Python application successfully asks for a Request Token and then redirects to the Google login page asking to grant access to my website. When I grant access I retrieve a 200 status code but exchanging this authorized request token for an access token gives me a 'The token is invalid' message.

The Google Oauth documentation says: "Google redirects with token and verifier regardless of whether the token has been authorized." so it seems that authorizing the request token fails but then I am not sure how I should get an authorized request token. Any suggestions?

Upvotes: 2

Views: 1394

Answers (1)

MorrisLiang
MorrisLiang

Reputation: 702

When you're exchanging for the access token, the oauth_verifier parameter is required. If you don't provide that parameter, then google will tell you that the token is invalid.

Upvotes: 1

Related Questions