Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Example of creating a OAuth2Credentials with dummy access token and a working refresh token
import datetime
import httplib2
from oauth2client.client import OAuth2Credentials
credentials = OAuth2Credentials("irrelevant access token",
"", # Client ID
"refresh-token",, # token expiry
http = httplib2.Http()
http = credentials.authorize(http)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment