AegisAI Perspectives · 154
Each Gmail API OAuth scope and Microsoft Graph mail permission an email security tool asks for, what it lets the tool do, and how an admin revokes it.
See it on your own Google Workspace or Microsoft 365 tenant. No MX change.
Or get the Q3 2026 State of the AI Attack report (free, instant download)
Not ready for a demo? Check your domain.

It is safer when each scope is read before approval and the change scopes come later. AegisAI works post-delivery through the Microsoft 365 or Google Workspace API21. Gmail API scopes and Microsoft Graph mail permissions each set a ceiling on what an email security tool can do, from seeing headers only to reading, changing, sending or deleting mail2.
If you run IT for a small business of 20 to 500 people on Google Workspace or Microsoft 365, with a small IT or security team and no SOC, use the reference table on this page to read a consent screen line by line. How the product reads and removes mail is on the inbound email security page. Whether to grant API access at all is answered in is it safe to give an email security vendor API access to our mailboxes. What AegisAI's AI agents read and keep is in how the AI agents are secured.
Key takeaways
| Question | Answer |
|---|---|
| Is it safe to give an email security vendor API access to our mailboxes? | It is safer when you know what each scope allows before you approve it. Microsoft calls admin consent a sensitive operation that can give the publisher access to significant portions of your data18 |
| Which Gmail scope reads mail without changing it? | gmail.readonly: view your email messages and settings |
| Which Gmail scope can delete mail permanently? | The full mail scope (mail.google.com), which can read, compose, send and permanently delete4 |
| Which Graph permission reads mail but not the body? | Mail.ReadBasic.All: every property except body, previewBody, attachments and extended properties12 |
| Which Graph permission lets a tool send as your users? | Mail.Send: send mail as any user without a signed-in user14 |
| How do you take access back? | Microsoft 365: Revoke permission on the Admin consent tab in Entra19. Google Workspace: delete the delegation client, or block the app,7 |
Short on time? Watch the explainer, or book a demo.
Reading needs a read scope; removal needs a scope that changes the mailbox. On Google Workspace, gmail.readonly views messages and settings. The modify scope goes on to compose and send3, and the full mail scope adds permanent deletion. On Microsoft 365, Mail.Read reads mail in all mailboxes. Mail.ReadWrite adds update and delete.
On Microsoft 365 the change tier does not send. Mail.ReadWrite does not include permission to send mail; sending is Mail.Send, a separate grant. On Google the tiers overlap: gmail.modify already includes sending, and gmail.send is a separate sensitive scope that only sends5.
Approve the read tier for the first step, and add the change tier only on the day you switch on removal.
Narrow the mailboxes first, then the permission. RBAC for Applications in Exchange Online pairs a permission grant with a resource scope that names the mailboxes an app can reach16. The two grants add up. Microsoft states that an unscoped Mail.Read grant from Entra ID plus a resource-scoped Mail.Read grant gives no effective resource scoping.
On Google Workspace, domain-wide delegation is not narrowed by mailbox. With domain-wide delegation, the app has access to the data belonging to all of your users9. The narrower Google lever is the scope itself: gmail.metadata sees labels and headers, not the body.
Check the Entra Admin consent tab for the same permission after you set any Exchange resource scope.
The restricted ones, because Google reviews the app behind them. Restricted scopes give wide access to Google user data and need restricted scope OAuth App Verification. An app that stores or transmits restricted scope data on its servers must also go through a security assessment6.
On Microsoft 365, the audit record starts at consent. Microsoft calls admin consent a sensitive operation, with full access to all mailboxes as its example. The Admin consent tab in Entra lists what was granted, and is where a grant is revoked.
Ask the vendor which restricted scopes it holds, and file the answer with the consent date.
Run these in order: once at approval, then again at each quarterly access review.
List each scope or permission on the consent screen and find its row in the reference table below.
On Google Workspace, set the app to Trusted, Limited or Blocked in the Admin console app access control.
If the app uses domain-wide delegation, go to Security, then Access and data control, then API controls. Open Manage Domain Wide Delegation and read the scopes on its client.
Restrict Gmail access to trusted apps in the Google Workspace Admin console; untrusted apps already installed then stop working and their tokens are revoked8.
On Microsoft 365, open the app under Enterprise apps in the Entra admin center. Read the Admin consent tab under Permissions.
Add an Exchange Online resource scope to limit mailboxes, then remove the matching unscoped Entra grant.
To revoke on Microsoft 365, pick the permission on the Admin consent tab and select Revoke permission.
To revoke on Google Workspace, delete the delegation client; apps that depend on it stop working at once. A Blocked app can't access any Google service.
Write the date and the approver next to each step in your change log.
The Gmail API scopes in this table are gmail.metadata, gmail.readonly, gmail.modify, gmail.send and the full mail scope. The Graph permissions are Mail.ReadBasic.All, Mail.Read, Mail.ReadWrite, Mail.Send and MailboxSettings.Read. Microsoft rows are application permissions, which act on all mailboxes without a signed-in user.
| Scope or permission | Platform | What it lets the tool do | Risk to weigh | How an admin reviews or revokes it |
|---|---|---|---|---|
| gmail.metadata | Google Workspace | View message metadata such as labels and headers, not the body | Restricted scope | Admin console app access: Trusted, Limited or Blocked |
| gmail.readonly | Google Workspace | View email messages and settings | Restricted scope | Same control; a Limited app reaches only unrestricted services |
| gmail.modify | Google Workspace | Read, compose and send email | Restricted scope | Same control |
| Full mail scope (mail.google.com) | Google Workspace | Read, compose, send and permanently delete all email | Restricted scope | Same control; ask why a narrower scope does not do the job |
| gmail.send | Google Workspace | Send email on the user's behalf | Sensitive scope | Same control |
| Mail.ReadBasic.All | Microsoft 365 | Read basic mail properties in all mailboxes, except body, previewBody, attachments and extended properties | No message body | Entra: Enterprise apps, Permissions, Admin consent |
| Mail.Read | Microsoft 365 | Read mail in all mailboxes; admin consent required | Full message content, tenant wide | Same tab; pair with an Exchange resource scope |
| Mail.ReadWrite | Microsoft 365 | Create, read, update and delete mail in all mailboxes; no sending | Can change and delete mail | Same tab; grant only when removal is switched on |
| Mail.Send | Microsoft 365 | Send mail as any user without a signed-in user | Mail that appears to come from your staff | Same tab; ask why a security tool needs it |
| Application MailboxSettings.Read | Microsoft 365 | Read users' mailbox settings in all mailboxes15 | Settings, not mail | Exchange Online RBAC for Applications |
Before you click Allow, question every scope that can change, send or delete mail.
A pilot runs read-only: the app can list users and read mail for classification, nothing more24. Quarantine mode adds a single permission to move malicious messages. Every permission is shown on the consent screen before you approve it. There is no MX record to change back and no connector to unwind25.
Track three numbers for each connected tool.
To see a real consent screen in your own tenant, walk through a connection with the team. On day 30, remove any grant nobody can explain.
It depends on the Gmail API scopes and Graph permissions the tool asks for, because each one caps what the tool can do. The reference table above shows what each one allows. In Entra, an admin consent grant is revoked on the Admin consent tab.
No. Mail.ReadWrite covers create, read, update and delete in all mailboxes. Sending needs Mail.Send.
Yes. gmail.metadata views message metadata such as labels and headers, but not the email body. Google still lists it as a restricted scope.
Access to every user's data in the domain. Google states that with domain-wide delegation, the app has access to the data belonging to all of your users. A super admin can delete the client, and dependent apps stop at once.
Yes, with RBAC for Applications in Exchange Online, which pairs a grant with a resource scope of named mailboxes. Remove any unscoped Mail.Read grant in Entra ID, or the scope has no effect.