-
Notifications
You must be signed in to change notification settings - Fork 370
Fix-6942-Added minimal permissions for 'entra m365group user' #6999
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -33,6 +33,25 @@ m365 entra m365group user list [options] | |
|
|
||
| <Global /> | ||
|
|
||
| ## Permissions | ||
|
|
||
| <Tabs> | ||
| <TabItem value="Delegated"> | ||
|
|
||
| | Resource | Permissions | | ||
| |-----------------|-----------------------------| | ||
| | Microsoft Graph | GroupMember.Read.All | | ||
|
|
||
| </TabItem> | ||
| <TabItem value="Application"> | ||
|
|
||
| | Resource | Permissions | | ||
| |-----------------|-----------------------------| | ||
| | Microsoft Graph | GroupMember.Read.All | | ||
|
|
||
| </TabItem> | ||
| </Tabs> | ||
|
Comment on lines
+38
to
+53
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This API appears to be a bit more complex. When an app only has The same applies to delegated scenarios, such as with |
||
|
|
||
| ## Remarks | ||
|
|
||
| When the `properties` option includes values with a `/`, for example: `manager/displayName`, an additional `$expand` query parameter will be included on `manager`. | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -37,6 +37,25 @@ m365 entra m365group user remove [options] | |
|
|
||
| <Global /> | ||
|
|
||
| ## Permissions | ||
|
|
||
| <Tabs> | ||
| <TabItem value="Delegated"> | ||
|
|
||
| | Resource | Permissions | | ||
| |-----------------|-----------------------------| | ||
| | Microsoft Graph | Group.ReadWrite.All | | ||
|
|
||
| </TabItem> | ||
| <TabItem value="Application"> | ||
|
|
||
| | Resource | Permissions | | ||
| |-----------------|-----------------------------| | ||
| | Microsoft Graph | Group.ReadWrite.All | | ||
|
|
||
| </TabItem> | ||
| </Tabs> | ||
|
Comment on lines
+44
to
+59
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. A simular suggestion as for |
||
|
|
||
| ## Remarks | ||
|
|
||
| You can remove users from a Microsoft 365 Group or Microsoft Teams team if you are owner of that group or team. | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -37,6 +37,25 @@ m365 entra m365group user set [options] | |
|
|
||
| <Global /> | ||
|
|
||
| ## Permissions | ||
|
|
||
| <Tabs> | ||
| <TabItem value="Delegated"> | ||
|
|
||
| | Resource | Permissions | | ||
| |-----------------|-----------------------------| | ||
| | Microsoft Graph | Group.ReadWrite.All | | ||
|
|
||
| </TabItem> | ||
| <TabItem value="Application"> | ||
|
|
||
| | Resource | Permissions | | ||
| |-----------------|-----------------------------| | ||
| | Microsoft Graph | Group.ReadWrite.All | | ||
|
|
||
| </TabItem> | ||
| </Tabs> | ||
|
Comment on lines
+44
to
+59
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The same suggestions as for |
||
|
|
||
| ## Remarks | ||
|
|
||
| The command will return an error if the user already has the specified role in the given Microsoft 365 Group or Microsoft Teams team. | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We’ll also need permissions when fetching users by
userNames. In that case, an extra call will be made to thev1.0/usersendpoint: https://learn.microsoft.com/en-us/graph/api/user-list?view=graph-rest-1.0&tabs=http#permissionsAdditionally, the docs mention that in delegated scenarios, the signed-in user must have at least a minimal role before being allowed to add new members (see the important admonition here: https://learn.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0&tabs=http#permissions).
We might want to include that information as well, though I’m not entirely sure what the cleanest way to handle it would be. @pnp/cli-for-microsoft-365-maintainers any thoughts?