Set Up the Third-Party Login#
A third-party login allows users to easily and quickly register in your community through the "Facebook", "Google", "Twitter" and "GitHub" portals. The advantage of this is that the profile data is taken over by the respective provider and the registration is done by a few clicks.
Note
Note that for security reasons the login is not supported for administrators via third parties!
Common to all vendors is that you have to create an application for the respective vendor, and get an ID and secret key, which must be entered into the settings (Admin Panel → Configuration → Options → User → Registration) of your community.
Facebook#
Note
You need: A free user account on Facebook, which has been authorized as a developer, and cURL (recommended) or allow_url_fopen on your webspace.
-
Go to the application overview at Facebook Developers.
-
Select Create a New App and choose a Display Name and Contact Email. Click on the Create App ID button and confirm the security query.
-
On the next page click on the product Facebook Login and click on the button Set up.
-
Go to Facebook Login → Settings in the left sidebar and enter the OAuth redirect URI in the Valid OAuth Redirect URIs field. You will find the appropriate redirect URI in the description of the input fields of the settings in the admin panel of your installation (Configuration → Options → User → Registration → Facebook APP-ID). Save your changes by clicking on the Save Changes button at the bottom of the screen.
-
To get your app ID and the associated secret code, select Settings → Basic from the menu on the left. Copy the information displayed there into the corresponding input fields of the settings in the admin panel of your installation.
-
Finally, toggle the In development switch in the header to make the app publicly available.
-
Done! You can now test the login by logging out of your community and clicking on the Facebook button.
Google#
Note
You need: A free user account at Google, which is linked to a handyname, and cURL (recommended) or allow_url_fopen on your webspace.
-
Go to the Cloud Console from Google. There you will find a list of your existing projects and the possibility to create a new project:
-
Select: Create Project. You do not have to change the suggestions in the fields, they are only for better administration. The creation can take a few minutes!
-
Once your project is created, you will be directed to the Dashoboard where the most popular APIs are listed. On the sidebar, click OAuth consent screen and select the External User Type and click Create.
-
In the next step, enter the name of your community and the links to your privacy policy and save them.
-
You must now specify the parameters to be queried. For this you have to click on Add or remove scopes.
-
Now select all available scopes (.auth/userinfo.email, .auth/userinfo.profile and openid).
-
Next, you need to create an OAuth client ID. To do this, click on Credentials in the sidebar.
-
Now click on Create Credentials and then on OAuth client ID.
-
Now select the Web application as Application type. Now enter any name for the key and store the Authorized redirect URIs. You will find the appropriate Authorized redirect URI in the description of the input fields of the settings in the admin panel of your installation (Configuration → Options → User → Registration → Google Client ID).
-
Now enter the displayed values Client ID and Client Secret into the corresponding settings of your community.
-
Done! You can now test the login by logging out of your community and clicking on the Google button.
Twitter#
Note
You need: A free user account at Twitter, and cURL (recommended) or allow_url_fopen on your webspace.
-
Go to the Developer Portal on Twitter. If you do not have a developer account on Twitter, you must apply for one. After the successful activation of your account as a developer, you can create a new app in the Developer Portal. To add a new application, first select the overview of the apps, you can find it under Projects & Apps → Overview in the left sidebar.
-
Click on the button Create App and enter an App name.
-
Now enter the API key and the API secret key in your community settings. Then click on App settings.
-
Now edit the Authentication settings.
-
Activate the option Enable 3-legged OAuth and the option Request email address from users. Also specify all required URLs here, especially the callback URL which you can find in the description of the input fields of the settings in the admin panel of your installation (Configuration → Options → Users → Registration → Twitter API key).
-
Done! You can now test the login by logging out of your community and clicking on the Twitter button.
GitHub#
Note
You need: A free user account at GitHub, and cURL (recommended) or allow_url_fopen on your webspace.
-
Go to the OAuth Apps on GitHub. You'll find a list of your existing applications above, as well as the ability to create a new application.
-
Select: *New OAuth App. There you fill in the fields as follows:
- Application name: Name of your community
- Homepage URL: Address of your community
- Application description: Description of your community (if desired)
- Authorization callback URL: Address of the callback URL (as specified in the settings Configuration → Options → User → Registration → GitHub Client ID of your community)
Now select Register application to create the application.
-
You will now get redirected to the information of your application. There you will also find the required Client ID and the required Client Secret, which you enter in the corresponding settings of your community.
-
Done! You can now test the login by logging out of your community and clicking again on the GitHub button.