Skip to content

Instantly share code, notes, and snippets.

@toughrogrammer
Last active June 11, 2016 05:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save toughrogrammer/447c50b16a41761aec53255be1bbfbd0 to your computer and use it in GitHub Desktop.
Save toughrogrammer/447c50b16a41761aec53255be1bbfbd0 to your computer and use it in GitHub Desktop.
def refreshing_oauth_token():
form_data = {
'grant_type': 'refresh_token',
'client_id': app.config.get('OAUTH_CLIENT_ID'),
'client_secret': app.config.get('OAUTH_CLIENT_SECRET'),
'refresh_token': REFRESH_TOKEN
}
response = RequestOauth.get_token(form_data)
oauth_access_token = response['access_token']
oauth_refresh_token = response['refresh_token']
response = make_response(render_template('jump.html', next=request.url))
return response
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment