Triggering authentication with /login
Triggering authentication with /login
# 👆 We're continuing from the steps above. Append this to your webappexample/views.py file. def login(request): return oauth.auth0.authorize_redirect( request, request.build_absolute_uri(reverse("callback")) )Finalizing authentication with /callback
# 👆 We're continuing from the steps above. Append this to your /views.py file. def callback(request): token = oauth.auth0.authorize_access_token(request) request.session["user"] = token return redirect(request.build_absolute_uri(reverse("index")))To inquire User roles
Last updated