Setup Facebook as an Identity Provider
This guide will help you set up Facebook as an identity provider for your Text Club
application. By integrating Facebook authentication, users can log in to your
application using their Facebook accounts, providing a seamless and secure login
experience.
Please follow the steps below to add Facebook authentication to your application.
Create a Facebook App
- Go to the Facebook Developers page and log in with your Facebook account.
- Click on the "My Apps" button.
- Click on the "Create App" button.
- Select "Authenticate and request data from users with Facebook Login" as the app type.
- Fill in the required details for your app, such as the app name, email, and purpose. Click "Create App ID".
- Complete the security check if prompted.
- Once your app is created, you will be redirected to the app dashboard.
Configure Facebook Login
- In the app dashboard, click on "Add a Product" in the left sidebar.
- Find "Facebook Login" and click on "Set Up".
- Choose "Web" as the platform.
- Enter your website URL in the "Site URL" field. This should be the URL of your Text Club application.
- Click "Save" to save the changes.
Set Up OAuth Redirect URI
- In the app dashboard, go to "Settings" in the left sidebar.
- Click on "Basic" under the "Settings" section.
- Scroll down to the "OAuth Redirect URIs" section.
-
Add the following URL to the "Valid OAuth Redirect URIs" field:
https://yourdomain.com/auth/facebook/callback
(replaceyourdomain.com
with your actual domain). - Click "Save Changes" to save the settings.
- Make sure to enable "Client OAuth Login" and "Web OAuth Login" in the "Client OAuth Settings" section.
Obtain the App ID and App Secret
- In the app dashboard, go to "Settings" in the left sidebar.
- Click on "Basic" under the "Settings" section.
- You will find your App ID and App Secret on this page.
- Click on "Show" next to the App Secret to reveal it. You may need to enter your Facebook password for security reasons.
- Copy the App ID and App Secret, as you will need them to configure Facebook authentication in your Text Club application.
Configure Facebook Authentication in Text Club
- Login to Text Club admin panel as an administrator.
- Navigate to Settings > Authentication.
- In the "Facebook" section, enter the App ID and App Secret you obtained from the Facebook Developers page.
- Click "Submit" to save the changes.