How to generate access token using refresh token through google drive API?

Niranja picture Niranja · May 17, 2012 · Viewed 99.5k times · Source

I have completed steps of authorization and obtained access token and refresh token.

What should I do next to generate access token using refresh token that I have stored through google drive API?

I won't be able to use any sdk since I am working on Force.com so please suggest the way to implement it directly through the API.

Answer

Claudio Cherubino picture Claudio Cherubino · May 17, 2012

If you want to implement that yourself, the OAuth 2.0 flow for Web Server Applications is documented at https://developers.google.com/accounts/docs/OAuth2WebServer, in particular you should check the section about using a refresh token:

https://developers.google.com/accounts/docs/OAuth2WebServer#refresh