PhoenixKitWeb.Users.OAuth (phoenix_kit v1.6.16)
View SourceOAuth authentication controller using Ueberauth with dynamic provider configuration.
This controller uses Ueberauth.run_request/4 and Ueberauth.run_callback/4 for
dynamic OAuth invocation, eliminating compile-time configuration requirements.
OAuth credentials are loaded from database at runtime.
This controller requires the following optional dependencies to be installed:
- ueberauth
- ueberauth_google (for Google Sign-In)
- ueberauth_apple (for Apple Sign-In)
- ueberauth_github (for GitHub Sign-In)
- ueberauth_facebook (for Facebook Sign-In)
If these dependencies are not installed, a fallback controller will be used instead.
Summary
Functions
Handles OAuth callback from provider.
Uses Ueberauth.run_callback/4 for dynamic OAuth invocation,
then processes the result from conn.assigns.
Initiates OAuth authentication flow.
Uses Ueberauth.run_request/4 for dynamic OAuth invocation,
reading credentials from database at runtime.