Social Login in Oracle APEX using Google
In the digital era, user authentication plays a vital role in web applications. A smooth and convenient authentication experience not only boosts user satisfaction but also simplifies the onboarding process. One effective method is integrating social sign-in options, enabling users to authenticate using their social media accounts.
In this blog post, we will explore the process of implementing a Social Sign-In feature in an Oracle APEX Application, specifically focusing on authenticating users using their Google accounts. By integrating Google's authentication services into your APEX applications, you can offer your users a hassle-free login experience while leveraging the power of their Google credentials.
Step 1: Register app and get Client Id and Client Secret from Google Cloud.
To implement social sign-in with Google in your Oracle APEX application, you need to register your app and obtain the Client ID and Client Secret from the Google Cloud Platform.
Here are the steps to follow:
Go to the Google Cloud Platform Console (https://console.cloud.google.com/).
If you don't have a project yet, create a new one by clicking on the project dropdown at the top of the page and selecting "New Project." Otherwise, select the desired project from the dropdown.
Next, you need to configure the consent screen. The consent screen is where you provide information about your application and obtain user consent.
Navigate to the "APIs & Services" section and click on "OAuth consent screen." Select "External" and click "Create".
Fill in the required information, including your application name, application logo, support email, and developer contact email. Click "SAVE AND CONTINUE"
On Scope configuration page, we are not going to set any scope so click "SAVE AND CONTINUE".On Test Users configuration screen, click "SAVE AND CONTINUE"
Next, click on the "Credentials" tab in the left sidebar.
Click the "Create Credentials" button and select "OAuth client ID" from the dropdown menu.
In the "Application type" section, choose "Web application" and provide Application Name.
To specify the Authorized Redirect URI, you must provide the callback URL of your Oracle APEX application. This callback URL is crucial for the authentication process and ensures that users are redirected back to your application after successfully authenticating with their Google accounts.
The format of the callback URL is https://<server>/ords/apex_authentication.callback
After specifying all the values, click on "Create" button.
Take note of the generated Client ID and Client Secret as you will need them to configure the social sign-in feature in your Oracle APEX application.
Step 2: Setup Web Credentials in Oracle APEX
Go to App Builder -> Workspace Utilities -> All Workspace Utilities
Comments
Post a Comment