Pre-requisites
Users with an existing GCP environment, it is recommended to have a new project that links to your Google Workspace via the registered domain
Admin Access to the Domain DNS Settings
Google Workspace Super Administrator access to authorize domain-wide delegation
Setup Google Workspace
Setting up Google Workspace involves several steps, depending on whether you create a new account or manage an existing domain.1
Configure a New Project in GCP
GCP is hierarchical, so we must first create a project. If you already have a GCP environment set up, we recommend following similar steps below to create a new project that links to your Google Workspace via the registered domain.
- Go to Google Cloud Console.
Sign in with your Google account used to set up Google Workspace.
- Click on the project selector (top-left dropdown near “Google Cloud”).
- Click “New Project” to configure the project with all the necessary details:
- Project Name: Enter a unique name for your project (For example: AirMDR).
- Organization & Location: Enter airmdr.com as organization and location or your organization and your location.
- Click Create.
Now you have Successfully created a New Organization and Project in GCP
Only the creator of the project has the right to manage the project.
2
Enable Admin SDK API and Google Workspace Alert center API
- Go to Google Cloud Console → APIs & Services → Library.
- Click Enable APIs and services in the top menu.
- Search for Each API:
- Search “Admin SDK API”, click it, and click “Enable”.
- Search “Google Workspace Alert Center API”, click it, and click “Enable”.
- Search “Google Drive API”, click it, and click “Enable”.
- Search “Gmail API”, click it, and click “Enable”.
When finished, you will have enabled the Admin SDK API within your project, where your service account will have access to pull data from Google Workspace.
Navigate to APIs & Services → Enabled APIs & services and confirm that every required API appears in the enabled list.
3
Configure OAuth Consent Screen in Google Cloud Platform (GCP)
- Go to the Google Cloud Console.
- Select your project.
- Navigate to “APIs & Services” → “OAuth consent screen” in the left-navigation pane.
- Click Get started.
- Configure App Information with the required details:
- App Name: airmdr-agent
- User Support Email: Provide an email for users to contact (For Example: your email address), and Click Next.
- Choose Audience as Internal.
- Provide the Developer Contact Information: (For Example: your email address), and click Next.
- In Finish, mark the checkbox to acknowledge and accept the terms of Google User Data Policy.
- Click “Create”.
After successful configuration, we will now have a registered application using OAuth 2.0 for authorization and the consent screen information setThe default token request limit for this app daily is 10,000 and can be increased on request.
4
Create a Service Account in Google Cloud
A service account is required for the AirMDR agent to ingest data from Google WorkspaceThis account is meant for non-human applications, allowing it to access resources in GW via the Admin SDK API we enabled earlier.
This is required to access Google Workspace APIs like Admin SDK API and Google Workspace Alert Center API.
- Go to Google Cloud Console → APIs & Services → Credentials → + Create credentials → Service account.

- On the “Create Service Account” page provide the required details:
- Service account name:
airmdr-agent - Service account ID:
airmdr-agent - Service account Description: Describe what this service account will do
- Service account name:
- Click “Create and Continue”.
- Assign necessary roles to grant permissions:
- “Service Account Token Creator”
- “Viewer” or “Editor” (if needed for managing resources)
- Click “Done”.

- Click on the newly created service account.
- Go to the “Keys” tab.
- Click “Add Key” → “Create New Key”.
After successful configuration, we will now have a service account named airmdr-agent, a Service Account JSON file with the necessary credentials for this service account saved to your host.
Securely save and share the downloaded Service Account JSON file to AirMDR.
Sample Service Account JSON
Sample Service Account JSON
By default, the Owner role will be applied to this service account based on inheritance from the project
5
Enable Domain-Wide Delegation
Only admins can perform this action.
- Go to Google Workspace Admin Console.
- Navigate to Security → Access and data control → API controls.
- Under Domain Wide Delegation, select Manage Domain Wide Delegation → Add a new client ID and enter the required credentials:
- OAuth 2.0 Client ID
- OAuth Scopes

- Click “AUTHORIZE”.
- Open the newly added client and select View details.
- Confirm that all required scopes are displayed.
Now you have Successfully enabled Domain-wide Delegation in Google Workspace
AirMDR requires both the Service Account JSON and an
The impersonated user must have the privileges required by the enabled AirMDR skills.
admin_email_id. The Service Account JSON authenticates the AirMDR service account, while admin_email_id identifies the active Google Workspace user that AirMDR impersonates when executing Google Workspace API requests. The impersonated user must have the privileges required by the enabled AirMDR skills.
Google Workspace OAuth Scope and AirMDR Capability Mapping:
- admin.reports.audit.readonly: To access Google Workspace Audit Reports
- apps.alerts: To read alerts
- admin.directory.user.readonly: To list users and get user details
- admin.directory.group.readonly: To list groups and retrieve group details
- admin.directory.user: To suspend or reactivate a Google Workspace user
- drive.readonly: To view and download Drive files
- gmail.readonly: To view Gmail messages and settings
6
Admin EmailID Requirement
The
admin_email_id field identifies the Google Workspace user that the AirMDR service account impersonates when making Google API requests.Required account characteristicsThe account entered as admin_email_id must:- Be an active Google Workspace user in the customer’s Workspace domain.
- Have Admin API → Users → Read permission.
- Have Admin API → Groups → Read permission.
- Have access to the Gmail and Google Drive resources that AirMDR must retrieve.
- Have the required Admin API privileges for the AirMDR skills being used.
- Have access to the required Alert Center, Reports, Gmail, and Drive resources.
- Remain active while the AirMDR connection is in use.
A dedicated Workspace account such as svc-airmdr-google@example.com is valid and preferred, provided it has the required Google Workspace privileges.Example:
admin_email_id: svc-airmdr-google@example.comGoogle confirms that administrative console privileges provide corresponding Admin API rights. It specifically supports Users → Read and Groups → Read API for delegated administrators.
✅ Summary of Retrieved Credentials
Securely save and share the
or
Self configure Google Workspace in the AirMDR Integrations Dashboard.
admin_email_id, and Service Account JSON file with the AirMDR team to configureor
Self configure Google Workspace in the AirMDR Integrations Dashboard.
Skills Provided by this Integration
Users and Access
Gmail
Google Drive
Alerts and Audit Logs
Threat Intelligence
Configure Google Workspace in AirMDR Integrations Dashboard
- Navigate to AirMDR, provide the credentials, and click Login.
- Navigate to the AirMDR Integrations Dashboard in the left navigation pane and select ADMIN → Integrations.
- Use the search option, enter the keyword “Google Workspace”, select the Connections tab, and click the Add New Connection icon.
- Enter the generated admin_email_id, provide the contents of the generated JSON file with Service Account credentials in the Authentication Details field params, and click Create.

