Follow this guide to get Auth0 setup in your Divjoy codebase. Click the ▶︎ icon next to any step to see a detailed walkthrough with screenshots. If anything is confusing please reach out.
Basic Setup
‣
‣
.env
file.‣
‣
You should now have working email and password authentication in your web app.
Enable Account Updating
Follow these steps to enable users to be able to update their email and password from the account settings UI in your web app.
‣
‣
‣
.env
file (the keys start with AUTH0_MANAGEMENT_
).After signing into your web app you should now be able to update your email and password from the account settings page.
Enable Social Authentication
Follow these steps to enable users to sign in with social auth providers, such as Google, Facebook, Twitter, etc.
‣
‣
- For Twitter, getting the email address requires some extra setup. Please see the Auth0 documentation on this.
‣
- If you want to use any other providers other than password, google, facebook, twitter, or github then you'll need to add them in your auth code. Follow this guide to do that.
You should now be able to sign in to your web app with social auth providers.
Other
- By default Auth0 has strict password rules (must be 8 or more chars, etc). You can adjust this in Dashboard → Connections → Database → Username-Password-Authentication → Password Policy.
- Users will be asked to verify their email after signing up. You can customize the email template in Dashboard → Emails → Templates. Keep in mind you'll need to specify a provider for email sending before custom templates will work.
- When a user requests to reset their password they will receive an email from Auth0 that takes them to an Auth0 hosted interface for changing their password. You can customize this email template in Dashboard → Emails → Templates.
- By default, if a user attempts to signup with an existing account they will get a generic “Invalid signup” message. You can change this to the more understandable “User already exists” error message by toggling a setting in Auth0. Please see the Auth0 documentation on this.