Using Google Account Authentication
Metric Insights users may access the system via an existing Google account rather than providing Metric Insights account username/password. Google's OAuth2/OpenID API is used by MI to authenticate and get user info for syncing.
PREREQUISITES:
Before configuring authentication parameters in Metric Insights, follow the procedure described to access Google APIs. This facility makes use of the PHP client library described here.
1. Setting Up Configuration Parameters
In order to configure System Variables, click the gear icon in the respective field:
- GOOGLE_OAUTH2_ALLOWED_DOMAINS: optional, but recommended for security reasons
- GOOGLE_OAUTH2_CLIENT_ID: specify the Client ID from the Google Client App you have created for integration
- GOOGLE_OAUTH2_CLIENT_SECRET: input the Client Secret from the Google Client App you have created for integration
- GOOGLE_OAUTH2_LOGIN: set to "Y" to enable Google Authentication
- GOOGLE_OAUTH2_REDIRECT_URI: this URI has to be specified among the Authorized Redirect URIs in the Google API Console
[Commit Changes]
2. Sign In with Google
Once the GOOGLE_OAUTH2_LOGIN option is enabled under System Variables, a Google Sign in button is shown in addition to the standard MI Login button.
Click [Sign in] to login to Metric Insights via the Google account.
2.1. Consent Screen
When logging in to the Metric Insights application via Google account for the first time, the user shall provide consent for the application to perform the specified actions.
Once the application receives user's permission to view his basic profile information, Metric Insights automatically creates (or updates) a user account based on the information received and a user is logged in the application on Homepage.