- A backend API endpoint that can receive GET requests with tokens and session details as URL parameters
- The ability to parse JWT tokens on your server to extract user details
- Your server configured to create login sessions for authenticated users
- Your social login providers already configured (Facebook, Google, and/or Apple)
Understanding the parameters
Each social login method accepts these parameters:- redirectUri (required): Your backend API endpoint URL. After login completes, the webview redirects here with the authentication token added as a URL parameter.
- scope (optional): Defines what user data your app can access. Each provider has different scope options:
- state (optional): An optional string you supply to verify the request came from your app. We’ll pass this back to you unchanged. Use it to prevent CSRF attacks.
What you’ll receive
When login succeeds, yourredirectUri receives the authentication tokens as URL parameters. If the user cancels the login process, the error parameter will contain an error message.
Redirect URL API endpoint parameters
Apple only includes
firstName and lastName on the user’s first login. See Platform-specific requirements.
Platform-specific requirements
- Sign in with Apple
- Facebook on iOS
Apple only sends complete user profile data (
firstName, lastName, email) on the first login. After that, you only get a JWT token and a user identifier.Here’s what to do:- Save the full user profile to your database during the first authentication
- On subsequent logins, retrieve the stored profile using the user identifier from the JWT
- Parse the JWT for additional fields like email and email_verified