Configure admin-authorized mailbox access for Google Workspace (via service account)#
6 min read
Supported platforms:
Google
Revenue Grid supports admin-authorized access to Gmail mailboxes using a secure, service-based integration with Google Workspace. In this model, an administrator configures access centrally — so individual users don’t need to grant permissions manually or reconnect their mailboxes after password changes.
This approach is ideal for organizations that want to streamline onboarding, maintain centralized control, and ensure uninterrupted data capture across all authorized users.
To enable this model, you’ll configure a Google Workspace service account with the necessary permissions and scopes, then upload its credentials in Revenue Grid. Once configured, the service account can access users’ Gmail, Calendar, Contacts, and Tasks data, as authorized by your domain settings.
Note: All configuration actions are performed in your Google Workspace environment by a super admin. Revenue Grid accesses and processes data in line with our privacy and security policies.
Before you begin#
Make sure the following prerequisites are met:
You have a platform admin or profile admin account in Revenue Grid.
All required user profiles have been created in Revenue Grid.
You have Google Workspace super admin permissions to configure APIs, OAuth clients, and domain‑wide delegation.
For instructions on how to create profiles, see Create and configure user profiles.
Step 1: Create a project#
Open the Google Cloud Console at https://console.developers.google.com/ and sign in with a Google Workspace super admin account.
Click the button Select a project ▾ in the upper-left corner.
Click NEW PROJECT.
Enter a project name (for example,
Gmail Service Account) and click CREATE.
After the project is created, make sure it is selected in the console.
Step 2: Enable Gmail API and related APIs#
Enabling Gmail and related APIs is a prerequisite for granting the service account the necessary access scopes later.
Step 3: Create a service account#
In the Google Cloud Console, click the menu icon (1), then go to IAM & Admin (2) > Service Accounts (3).
Click + CREATE SERVICE ACCOUNT.
Enter a Service account name (such as
RG Gmail Service Account) and an optional description, then click CREATE AND CONTINUE.
In the Role dropdown, select Project > Owner (this can be restricted later as appropriate), then click CONTINUE.
Click DONE to complete service account creation.
In the Service accounts list, locate the newly created account and click the three-dot icon > Manage keys.
Click ADD KEY > Create new key.
Leave the key format as JSON and click CREATE.
A JSON key file will download automatically — store it securely, as it will be used later when configuring Revenue Grid.
Open the DETAILS tab.
Scroll down, expand Advanced settings, and copy the Client ID value.
Save the Client ID somewhere secure — you will use it in later steps when configuring Google Workspace access.
Step 4: Configure the OAuth consent screen#
In the Google Cloud Console, go to APIs & Services > OAuth consent screen.
Select Internal user type and click CREATE.
On the App information page:
Under Authorized domains, click ADD DOMAIN and enter
revenuegrid.com.
Enter your organization’s admin email under Developer contact information, then click SAVE AND CONTINUE.
On the Scopes page, click ADD OR REMOVE SCOPES and manually add the following comma‑separated scopes:
https://www.googleapis.com/auth/gmail.readonly, https://www.google.com/m8/feeds/, https://www.googleapis.com/auth/calendar, https://www.googleapis.com/auth/drive, https://www.googleapis.com/auth/drive.appdata, https://www.googleapis.com/auth/gmail.labels, https://www.googleapis.com/auth/gmail.modify, https://www.googleapis.com/auth/tasks, https://www.googleapis.com/auth/userinfo.email, https://www.googleapis.com/auth/gmail.compose, https://www.googleapis.com/auth/contacts, https://www.googleapis.com/auth/userinfo.profile
After adding the scopes, click ADD TO TABLE, then SAVE AND CONTINUE.
Review the consent screen summary and click BACK TO DASHBOARD.
Step 5: Enable the service account in Google Workspace#
Open the Google Workspace Admin Console at https://admin.google.com/ and sign in with super admin credentials.
In the navigation panel, go to Security.
Under Access and data control, click API controls.
On the API Controls page, click MANAGE THIRD‑PARTY APP ACCESS.
Click Configure new app > OAuth App Name Or Client ID.
Paste the Client ID you copied earlier and click SEARCH.
Select the Revenue Grid app from the search results and click Select.
Select the checkbox next to the Client ID, then click SELECT.
Set App access to Trusted: Can access all Google services, and click CONFIGURE.
Step 6: Set up domain-wide delegation#
In the Google Workspace Admin Console, open the Security tab and go to Access and data control > API controls.
Under Domain-wide delegation, click MANAGE DOMAIN‑WIDE DELEGATION.
Click Add new API client.
Enter the Client ID from Step 3.
In the OAuth scopes field, enter the following comma‑separated scopes:
https://www.googleapis.com/auth/gmail.readonly, https://www.google.com/m8/feeds/, https://www.googleapis.com/auth/calendar, https://www.googleapis.com/auth/drive, https://www.googleapis.com/auth/drive.appdata, https://www.googleapis.com/auth/gmail.labels, https://www.googleapis.com/auth/gmail.modify, https://www.googleapis.com/auth/tasks, https://www.googleapis.com/auth/userinfo.email, https://www.googleapis.com/auth/gmail.compose, https://www.googleapis.com/auth/contacts, https://www.googleapis.com/auth/userinfo.profile
Click AUTHORISE.
Wait up to a few minutes for domain‑wide delegation to propagate.
Step 7: Configure mailbox connectivity in Revenue Grid#
Open the Revenue Grid settings.
Under Administration, go to Profiles.
Open the profile you want to configure and go to the Connectivity tab.
In the Email configuration section, open the Mailbox access type menu and select Google Service Account.
Under Upload JSON file, click Choose File, select the
.jsonkey file you downloaded in Step 3, then click Upload.
Click Save to apply the changes.
The service account is now configured to manage Gmail access for all assigned users. Users do not need to authorize their own mailboxes individually. Revenue Grid can now access Gmail, Calendar, Contacts, and other supported data types, as permitted by the scopes you configured.