Connect Google Workspace
Aatrex connects to Google Workspace through a service account with domain-wide delegation. You create the service account in your own Google Cloud project, a Super Admin authorises it for the scopes your workloads need, and you upload its key to Aatrex. No user passwords are involved.
Step 1 — Create the service account
- Sign in to the Google Cloud console and create a project (or pick an existing one).
- Under APIs & Services → Library, enable the APIs for your workloads: Gmail API, Google Calendar API, People API, Google Drive API and Admin SDK API — plus Google Chat API for Chat.
- Under IAM & Admin → Service Accounts, create a service account. It needs no project roles.
- Open it, go to Keys → Add key → Create new key → JSON, and keep the downloaded file safe.
- On the Details tab, copy the numeric Client ID.
Step 2 — Authorise domain-wide delegation
- Sign in to admin.google.com as a Super Admin.
- Go to Security → Access and data control → API controls → Manage domain-wide delegation.
- Click Add new, paste the Client ID, and enter the scopes for the side and workloads you're migrating.
Source (migrating from Google) — read-only:
https://www.googleapis.com/auth/gmail.readonly,
https://www.googleapis.com/auth/calendar.readonly,
https://www.googleapis.com/auth/contacts.readonly,
https://www.googleapis.com/auth/drive.readonly,
https://www.googleapis.com/auth/admin.directory.user.readonly
Destination (migrating to Google):
https://mail.google.com/,
https://www.googleapis.com/auth/calendar,
https://www.googleapis.com/auth/contacts,
https://www.googleapis.com/auth/drive,
https://www.googleapis.com/auth/admin.directory.user.readonly
Google Chat uses its own scopes — see the Security page or the chat migration guides.
Google refuses a sign-in that asks for a scope that isn't authorised, so Aatrex asks only for the scopes the workload in that run needs. Authorise exactly the list for your side.
Step 3 — Upload the key
In the project wizard, choose Service Account JSON, upload the key, and enter a Google Workspace Super Admin email (the account Aatrex impersonates to list users). The key is encrypted with AES-256-GCM before it is stored.
Click Test connection: Aatrex signs in as the service account and lists users through the Admin SDK, which confirms the delegation works. A scope missing for a particular workload shows up as an error on that workload's first run. Delegation changes can take a few minutes to apply.
Revoke access
- In the Google Admin console → Security → API controls → Domain-wide delegation, delete the Client ID. Jobs stop straight away.
- To also remove the key, delete it under the service account's Keys tab in Google Cloud.
Related: Permissions & Access · Google Workspace → Microsoft 365