Skip to content

Instantly share code, notes, and snippets.

Last active Dec 7, 2021
What would you like to do?
Stytch Google OAuth
from flask import Flask
from flask import request
from flask import render_template
from flask import session
app = Flask(__name__)
app.secret_key = "development"
def login():
"""Login a user."""
if "token" in request.url:
access_token = request.args.get("token")
session["token"] = access_token # TOOD: move to a DB in production, and do something safer and scaleable :)
return render_template('login.html')
def sign_up():
"""Placeholder sign up route for interacting with Stytch API."""
if __name__ == "__main__":, debug=True)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment