Gmail OAuth Email Monitoring
Last updated on 22 November, 2024LogicMonitor offers Gmail service monitoring for health metrics, including round-trip time and transit time.
Requirements for Monitoring Gmail OAuth Email
To monitor Gmail service monitoring, you need the following:
- Google Account
- LogicModules for Email Service monitoring installed
For more information, see Email Service Modules.
In addition, you need the following from your Google Cloud Console to add the values as properties in your LogicMonitor portal:
- Client ID and Client secret from your Google Cloud Console
To do this you need to set up Google Workspace and enable Gmail API. For instructions on how to do this, see Develop on Google Workspace and Setting up OAuth 2.0 from Google. - Refresh token
To generate a refresh token, see OAuth 2.0 Playground from Google.
Warning: To properly configure the environment when generating a token, you need to use your own OAuth credentials, and set the selected scope to https://mail.google.com/.
Resource Properties
The following properties must be set in LogicMonitor using the values you obtain from your Google Cloud Console. For more information on setting properties, see Resource and Instance Properties.
Property | Value |
gmail.refresh.key | The refresh key obtained from Google Playground |
gmail.client.id or email.user | The Gmail Client ID |
gmail.client.secret.pass or email.pass | The Gmail Client Secret |
Monitoring Gmail OAuth Email
To monitor email transit time, create instances for each transit direction.
- From the LogicMonitor Resources page, navigate to the
Email_TransitTime
DataSource. - From the Manage Device menu, select Add Monitored Instance.
- From the Add Monitored Instance page, enter the Name and Wildvalue information, based on the following example:
- Name: Gmail > O365
- Wildvalue (sender:receiver): gmail:o365
- Instance Group: @default
- Select Save.
- Return to the Resources page and create a second monitored instance for the
Email_TransitTime
DataSource, based on the following example:- Name: O365 > Gmail
- Wildvalue (sender:receiver): o365:gmail
- Instance Group: @default
- Select Save.
For information, see Email Service Monitoring.
Troubleshooting Gmail OAuth Monitoring
Ensure that IMAP is enabled in Gmail settings. For more information, see Set up Gmail with a third-party email client from Google.