ESC
Type to search...

Mail-Advanced.ReadWrite.All

Export JSON
Export CSV
Copy URL
Print
Application Read/Write All Resources

Allows the app to create, read, update, and delete all email, including contents of non-draft emails in user mailboxes, without a signed-in user. Does not include permission to send mail.

In short

Mail-Advanced.ReadWrite.All is an application-only permission in the Microsoft Graph API, grouped under the Mail-Advanced category. Allows the app to create, read, update, and delete all email, including contents of non-draft emails in user mailboxes, without a signed-in user. Does not include permission to send mail. It grants read and write access to resources. Application permissions always require admin consent.

Permission data: November 17, 2026 at 3:06 AM UTC
Delegated Access App-Only Access

Permission Details

Application Permission

Read and write mail in all mailboxes, including modifying existing non-draft mails

Allows the app to create, read, update, and delete all email, including contents of non-draft emails in user mailboxes, without a signed-in user. Does not include permission to send mail.

Properties

Microsoft Graph v1.0 endpoint-derived-docs

Properties is shown from stable Microsoft Graph v1.0 metadata.

Property Type Description
childFolderCount Int32Nullable The number of immediate child mailFolders in the current mailFolder.
displayName StringNullable The mailFolder's display name.
id String The mailFolder's unique identifier.
isHidden BooleanNullable Indicates whether the mailFolder is hidden. This property can be set only when creating the folder. Find more information in Hidden mail folders.
parentFolderId StringNullable The unique identifier for the mailFolder's parent mailFolder.
totalItemCount Int32Nullable The number of items in the mailFolder.
unreadItemCount Int32Nullable The number of items in the mailFolder marked as unread.
childFolders mailFolder collection The collection of child folders in the mailFolder.
messageRules messageRule collection The collection of rules that apply to the user's Inbox folder.
messages message collection The collection of messages in the mailFolder.
multiValueExtendedProperties multiValueLegacyExtendedProperty collection The collection of multi-value extended properties defined for the mailFolder. Read-only. Nullable.
singleValueExtendedProperties singleValueLegacyExtendedProperty collection The collection of single-value extended properties defined for the mailFolder. Read-only. Nullable.

JSON Representation

Microsoft Graph v1.0 endpoint-derived-docs

JSON representation is shown from stable Microsoft Graph v1.0 metadata.

JSON representation
{
  "childFolderCount": 1024,
  "displayName": "string",
  "id": "string (identifier)",
  "parentFolderId": "string",
  "totalItemCount": 1024,
  "unreadItemCount": 1024,
  "isHidden": false,
  "childFolders": [
    {
      "@odata.type": "microsoft.graph.mailFolder"
    }
  ],
  "messageRules": [
    {
      "@odata.type": "microsoft.graph.messageRule"
    }
  ],
  "messages": [
    {
      "@odata.type": "microsoft.graph.message"
    }
  ],
  "multiValueExtendedProperties": [
    {
      "@odata.type": "microsoft.graph.multiValueLegacyExtendedProperty"
    }
  ],
  "singleValueExtendedProperties": [
    {
      "@odata.type": "microsoft.graph.singleValueLegacyExtendedProperty"
    }
  ]
}

Relationships

Microsoft Graph v1.0 endpoint-derived-docs

Relationships is shown from stable Microsoft Graph v1.0 metadata.

Relationship Type Description
childFolders MailFolder collection The collection of child folders in the mailFolder.
messageRules messageRule collection The collection of rules that apply to the user's Inbox folder.
messages Message collection The collection of messages in the mailFolder.
multiValueExtendedProperties multiValueLegacyExtendedProperty collection The collection of multi-value extended properties defined for the mailFolder. Read-only. Nullable.
singleValueExtendedProperties singleValueLegacyExtendedProperty collection The collection of single-value extended properties defined for the mailFolder. Read-only. Nullable.
operations mailFolderOperation collection The collection of long-running operations in the mailFolder.
userConfigurations userConfiguration collection The user configuration objects associated to the mailFolder.

Graph Methods

Delegated access App-only access
Exact Microsoft Learn match

Microsoft Graph v1.0 endpoints are mapped directly from refreshed Microsoft Learn permissions tables.

No API methods available for this version.

Exact Microsoft Learn match

Microsoft Graph beta endpoints are mapped directly from refreshed Microsoft Learn permissions tables.

Methods
POST /me/mailFolders/{mailFolderId}/importMime
POST /users/{usersId}/mailFolders/{mailFolderId}/importMime
No Microsoft Learn PowerShell mapping available

Microsoft Graph PowerShell v1.0 commands are not available from refreshed Microsoft Learn PowerShell snippets for this permission.

No deterministic PowerShell command map is available for this permission.

Browse PowerShell docs
No Microsoft Learn PowerShell mapping available

Microsoft Graph PowerShell beta commands are not available from refreshed Microsoft Learn PowerShell snippets for this permission.

No deterministic PowerShell command map is available for this permission.

Browse PowerShell docs

Code Examples

C# / .NET SDK
using Azure.Identity;
using Microsoft.Graph;

var scopes = new[] { "Mail-Advanced.ReadWrite.All" };
var credential = new InteractiveBrowserCredential(
    new InteractiveBrowserCredentialOptions
    {
        ClientId = "YOUR_CLIENT_ID",
        TenantId = "YOUR_TENANT_ID",
        RedirectUri = new Uri("http://localhost")
    });

var graphClient = new GraphServiceClient(credential, scopes);
var response = await graphClient
    .WithUrl("https://graph.microsoft.com/v1.0/me/mailFolders/{id}/importMime")
    .GetAsync();
JavaScript
import { Client } from "@microsoft/microsoft-graph-client";
import { InteractiveBrowserCredential } from "@azure/identity";

const credential = new InteractiveBrowserCredential({
  clientId: "YOUR_CLIENT_ID",
  tenantId: "YOUR_TENANT_ID",
  redirectUri: "http://localhost"
});

const token = await credential.getToken(["Mail-Advanced.ReadWrite.All"]);
const client = Client.init({
  authProvider: (done) => done(null, token.token)
});

const response = await client.api("/me/mailFolders/{id}/importMime").get();
PowerShell
Connect-MgGraph -Scopes "Mail-Advanced.ReadWrite.All"
Invoke-MgGraphRequest -Method GET -Uri "https://graph.microsoft.com/v1.0/me/mailFolders/{id}/importMime"
Python
from azure.identity import InteractiveBrowserCredential
import requests

credential = InteractiveBrowserCredential(
    client_id="YOUR_CLIENT_ID",
    tenant_id="YOUR_TENANT_ID"
)

token = credential.get_token("Mail-Advanced.ReadWrite.All")
response = requests.get(
    "https://graph.microsoft.com/v1.0/me/mailFolders/{id}/importMime",
    headers={"Authorization": f"Bearer {token.token}"}
)

print(response.json())

App Registration

1

Navigate to Azure Portal

Go to App registrations in Microsoft Entra admin center

2

Add API Permission

Select your app → API permissions → Add a permission → Microsoft Graph

3

Select Permission Type

Choose Application permissions and search for Mail-Advanced.ReadWrite.All

4

Grant Admin Consent

Application permissions always require admin consent.

Frequently asked questions

What is the Mail-Advanced.ReadWrite.All Microsoft Graph permission?

Mail-Advanced.ReadWrite.All is an application-only permission in the Microsoft Graph API, grouped under the Mail-Advanced category. Allows the app to create, read, update, and delete all email, including contents of non-draft emails in user mailboxes, without a signed-in user. Does not include permission to send mail. It grants read and write access to resources. Application permissions always require admin consent. It is mapped to the Microsoft Graph mailfolder resource type. 2 documented Microsoft Graph REST methods require it.

Is Mail-Advanced.ReadWrite.All an application or a delegated permission?

Mail-Advanced.ReadWrite.All is an application permission only. It grants app-only access without a signed-in user and always requires admin consent.

Does Mail-Advanced.ReadWrite.All require admin consent?

Application permissions always require admin consent.

What is the permission ID (GUID) for Mail-Advanced.ReadWrite.All?

For Mail-Advanced.ReadWrite.All, the application (app role) ID is e118f1da-5c1c-46cf-bff6-8858d786f46f. These are the real Microsoft Graph identifiers and can be used directly in an app registration manifest.