Skip to content

Commit 11a311a

Browse files
authored
Add info on custom scopes for microsoft entra id creds (#3137)
1 parent bb29bbf commit 11a311a

File tree

1 file changed

+25
-6
lines changed

1 file changed

+25
-6
lines changed

docs/integrations/builtin/credentials/microsoftentra.md

+25-6
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ You can use these credentials to authenticate the following nodes:
1717
- Create a Microsoft Entra ID account or subscription.
1818
- If the user account is managed by a corporate Microsoft Entra account, the administrator account has enabled the option “User can consent to apps accessing company data on their behalf” for this user (see the [Microsoft Entra documentation](https://learn.microsoft.com/en-us/entra/identity/enterprise-apps/grant-admin-consent)).
1919

20-
Microsoft includes an Entra ID free plan when you create a [Microsoft Azure](https://azure.microsoft.com/){:target=_blank .external-link} account.
20+
Microsoft includes an Entra ID free plan when you create a [Microsoft Azure](https://azure.microsoft.com/) account.
2121

2222
## Supported authentication methods
2323

2424
- OAuth2
2525

2626
## Related resources
2727

28-
Refer to [Microsoft Entra ID's documentation](https://www.microsoft.com/en-us/security/business/identity-access/azure-active-directory){:target=_blank .external-link} for more information about the service.
28+
Refer to [Microsoft Entra ID's documentation](https://www.microsoft.com/en-us/security/business/identity-access/azure-active-directory) for more information about the service.
2929

3030
## Using OAuth2
3131

@@ -36,13 +36,13 @@ For self-hosted users, there are two main steps to configure OAuth2 from scratch
3636
1. [Register an application](#register-an-application) with the Microsoft Identity Platform.
3737
2. [Generate a client secret](#generate-a-client-secret) for that application.
3838

39-
Follow the detailed instructions for each step below. For more detail on the Microsoft OAuth2 web flow, refer to [Microsoft authentication and authorization basics](https://learn.microsoft.com/en-us/graph/auth/auth-concepts){:target=_blank .external-link}.
39+
Follow the detailed instructions for each step below. For more detail on the Microsoft OAuth2 web flow, refer to [Microsoft authentication and authorization basics](https://learn.microsoft.com/en-us/graph/auth/auth-concepts).
4040

4141
### Register an application
4242

4343
Register an application with the Microsoft Identity Platform:
4444

45-
1. Open the [Microsoft Application Registration Portal](https://aka.ms/appregistrations){:target=_blank .external-link}.
45+
1. Open the [Microsoft Application Registration Portal](https://aka.ms/appregistrations).
4646
2. Select **Register an application**.
4747
3. Enter a **Name** for your app.
4848
4. In **Supported account types**, select **Accounts in any organizational directory (Any Azure AD directory - Multi-tenant) and personal Microsoft accounts (for example, Skype, Xbox)**.
@@ -53,7 +53,7 @@ Register an application with the Microsoft Identity Platform:
5353
6. Select **Register** to finish creating your application.
5454
7. Copy the **Application (client) ID** and paste it into n8n as the **Client ID**.
5555

56-
Refer to [Register an application with the Microsoft Identity Platform](https://learn.microsoft.com/en-us/graph/auth-register-app-v2){:target=_blank .external-link} for more information.
56+
Refer to [Register an application with the Microsoft Identity Platform](https://learn.microsoft.com/en-us/graph/auth-register-app-v2) for more information.
5757

5858
### Generate a client secret
5959

@@ -68,7 +68,26 @@ With your application created, generate a client secret for it:
6868
1. Select **Connect my account** in n8n to finish setting up the connection.
6969
1. Log in to your Microsoft account and allow the app to access your info.
7070

71-
Refer to Microsoft's [Add credentials](https://learn.microsoft.com/en-us/graph/auth-register-app-v2#add-credentials){:target=_blank .external-link} for more information on adding a client secret.
71+
Refer to Microsoft's [Add credentials](https://learn.microsoft.com/en-us/graph/auth-register-app-v2#add-credentials) for more information on adding a client secret.
72+
73+
## Setting custom scopes
74+
75+
Microsoft Entra ID credentials use the following scopes by default:
76+
77+
* [`openid`](https://learn.microsoft.com/en-us/entra/identity-platform/scopes-oidc#the-openid-scope)
78+
* [`offline_access`](https://learn.microsoft.com/en-us/entra/identity-platform/scopes-oidc#the-offline_access-scope)
79+
* [`AccessReview.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#accessreviewreadwriteall)
80+
* [`Directory.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#directoryreadwriteall)
81+
* [`NetworkAccessPolicy.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#networkaccesspolicyreadwriteall)
82+
* [`DelegatedAdminRelationship.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#delegatedadminrelationshipreadwriteall)
83+
* [`EntitlementManagement.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#entitlementmanagementreadwriteall)
84+
* [`User.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#userreadwriteall)
85+
* [`Directory.AccessAsUser.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#directoryaccessasuserall)
86+
* [`Sites.FullControl.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#sitesfullcontrolall)
87+
* [`GroupMember.ReadWrite.All`](https://learn.microsoft.com/en-us/graph/permissions-reference#groupmemberreadwriteall)
88+
89+
To select different scopes for your credentials, enable the **Custom Scopes** slider and edit the **Enabled Scopes** list. Keep in mind that some features may not work as expected with more restrictive scopes.
90+
7291

7392
## Common issues
7493

0 commit comments

Comments
 (0)