Skip to content

Instantly share code, notes, and snippets.

@leeyspaul
Last active November 30, 2021 20:29
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 leeyspaul/955568a36c532fcfd3b4df2987386f14 to your computer and use it in GitHub Desktop.
Save leeyspaul/955568a36c532fcfd3b4df2987386f14 to your computer and use it in GitHub Desktop.
OAuth2 Google Calendar API Redirect Route
@app.route("/oauth2redirect")
def oauth2_redirect():
"""
The redirect URI that Google hits after user grants access in the OAuth
consent screen where we fetch the access token from the access code given in the
URL and set them in the flask session.
"""
# grabs the URL response from the redirect after auth
authorization_response = request.url
return "OK" # placeholder
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment