@pnp/cli-microsoft365 11.0.0-beta.3d99ea3 → 11.0.0-beta.4abfd23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. package/.devproxy/api-specs/sharepoint.yaml +54 -0
  2. package/allCommands.json +1 -1
  3. package/allCommandsFull.json +1 -1
  4. package/dist/Command.js +4 -0
  5. package/dist/m365/adaptivecard/commands/adaptivecard-send.js +1 -1
  6. package/dist/m365/entra/commands/administrativeunit/administrativeunit-add.js +13 -27
  7. package/dist/m365/entra/commands/administrativeunit/administrativeunit-get.js +18 -43
  8. package/dist/m365/entra/commands/administrativeunit/administrativeunit-list.js +10 -21
  9. package/dist/m365/entra/commands/administrativeunit/administrativeunit-remove.js +25 -49
  10. package/dist/m365/entra/commands/group/group-member-add.js +6 -27
  11. package/dist/m365/entra/commands/group/group-member-set.js +5 -26
  12. package/dist/m365/entra/commands/m365group/m365group-get.js +1 -7
  13. package/dist/m365/entra/commands/m365group/m365group-list.js +1 -7
  14. package/dist/m365/entra/commands/pim/pim-role-assignment-eligibility-list.js +1 -7
  15. package/dist/m365/entra/commands/pim/pim-role-assignment-list.js +1 -7
  16. package/dist/m365/entra/commands/pim/pim-role-request-list.js +1 -7
  17. package/dist/m365/entra/commands/roleassignment/roleassignment-add.js +146 -0
  18. package/dist/m365/entra/commands.js +1 -0
  19. package/dist/m365/flow/commands/environment/environment-get.js +19 -29
  20. package/dist/m365/flow/commands/flow-list.js +7 -14
  21. package/dist/m365/flow/commands/run/run-get.js +1 -7
  22. package/dist/m365/graph/commands/openextension/openextension-add.js +2 -2
  23. package/dist/m365/graph/commands/openextension/openextension-set.js +2 -6
  24. package/dist/m365/graph/commands/subscription/subscription-add.js +3 -10
  25. package/dist/m365/pa/commands/environment/environment-get.js +18 -23
  26. package/dist/m365/pp/commands/copilot/copilot-get.js +0 -4
  27. package/dist/m365/pp/commands/copilot/copilot-list.js +0 -4
  28. package/dist/m365/pp/commands/copilot/copilot-remove.js +0 -4
  29. package/dist/m365/pp/commands/environment/environment-get.js +19 -26
  30. package/dist/m365/pp/commands/solution/solution-publisher-list.js +1 -8
  31. package/dist/m365/pp/commands.js +0 -3
  32. package/dist/m365/purview/commands/threatassessment/threatassessment-get.js +1 -7
  33. package/dist/m365/spfx/commands/project/project-upgrade.js +23 -66
  34. package/dist/m365/spo/commands/file/file-move.js +2 -8
  35. package/dist/m365/spo/commands/file/file-version-keep.js +78 -0
  36. package/dist/m365/spo/commands/homesite/homesite-get.js +28 -14
  37. package/dist/m365/spo/commands/homesite/homesite-list.js +1 -12
  38. package/dist/m365/spo/commands/homesite/homesite-remove.js +6 -34
  39. package/dist/m365/spo/commands/hubsite/hubsite-get.js +4 -13
  40. package/dist/m365/spo/commands/hubsite/hubsite-list.js +1 -8
  41. package/dist/m365/spo/commands/list/list-view-add.js +1 -1
  42. package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-grant-list.js +17 -25
  43. package/dist/m365/spo/commands/{tenant/tenant-site-archive.js → site/site-archive.js} +14 -14
  44. package/dist/m365/spo/commands/{tenant/tenant-site-list.js → site/site-list.js} +16 -27
  45. package/dist/m365/spo/commands/{tenant/tenant-site-membership-list.js → site/site-membership-list.js} +15 -15
  46. package/dist/m365/spo/commands/{tenant/tenant-site-rename.js → site/site-rename.js} +14 -14
  47. package/dist/m365/spo/commands/{tenant/tenant-site-unarchive.js → site/site-unarchive.js} +14 -14
  48. package/dist/m365/spo/commands/term/term-list.js +1 -7
  49. package/dist/m365/spo/commands.js +5 -6
  50. package/dist/m365/teams/commands/chat/chat-member-add.js +3 -9
  51. package/dist/m365/viva/commands/engage/engage-network-list.js +1 -7
  52. package/dist/utils/entraAdministrativeUnit.js +1 -1
  53. package/docs/docs/cmd/entra/group/group-member-add.mdx +7 -26
  54. package/docs/docs/cmd/entra/group/group-member-set.mdx +5 -23
  55. package/docs/docs/cmd/entra/m365group/m365group-get.mdx +0 -3
  56. package/docs/docs/cmd/entra/m365group/m365group-list.mdx +0 -3
  57. package/docs/docs/cmd/entra/pim/pim-role-assignment-eligibility-list.mdx +0 -3
  58. package/docs/docs/cmd/entra/pim/pim-role-assignment-list.mdx +0 -3
  59. package/docs/docs/cmd/entra/pim/pim-role-request-list.mdx +0 -3
  60. package/docs/docs/cmd/entra/roleassignment/roleassignment-add.mdx +163 -0
  61. package/docs/docs/cmd/flow/environment/environment-get.mdx +6 -5
  62. package/docs/docs/cmd/flow/flow-list.mdx +0 -3
  63. package/docs/docs/cmd/flow/run/run-get.mdx +0 -3
  64. package/docs/docs/cmd/graph/subscription/subscription-add.mdx +0 -3
  65. package/docs/docs/cmd/pa/environment/environment-get.mdx +5 -2
  66. package/docs/docs/cmd/pp/copilot/copilot-get.mdx +0 -6
  67. package/docs/docs/cmd/pp/copilot/copilot-list.mdx +0 -6
  68. package/docs/docs/cmd/pp/copilot/copilot-remove.mdx +0 -6
  69. package/docs/docs/cmd/pp/environment/environment-get.mdx +5 -2
  70. package/docs/docs/cmd/pp/solution/solution-publisher-list.mdx +0 -3
  71. package/docs/docs/cmd/purview/threatassessment/threatassessment-get.mdx +0 -3
  72. package/docs/docs/cmd/spfx/project/project-upgrade.mdx +18 -5
  73. package/docs/docs/cmd/spo/file/file-move.mdx +0 -3
  74. package/docs/docs/cmd/spo/file/file-version-keep.mdx +68 -0
  75. package/docs/docs/cmd/spo/homesite/homesite-get.mdx +44 -23
  76. package/docs/docs/cmd/spo/homesite/homesite-list.mdx +0 -6
  77. package/docs/docs/cmd/spo/homesite/homesite-remove.mdx +10 -35
  78. package/docs/docs/cmd/spo/homesite/homesite-set.mdx +1 -1
  79. package/docs/docs/cmd/spo/hubsite/hubsite-get.mdx +0 -3
  80. package/docs/docs/cmd/spo/hubsite/hubsite-list.mdx +0 -3
  81. package/docs/docs/cmd/spo/list/list-view-add.mdx +11 -11
  82. package/docs/docs/cmd/spo/serviceprincipal/serviceprincipal-grant-list.mdx +18 -18
  83. package/docs/docs/cmd/spo/{tenant/tenant-site-archive.mdx → site/site-archive.mdx} +4 -4
  84. package/docs/docs/cmd/spo/{tenant/tenant-site-list.mdx → site/site-list.mdx} +7 -16
  85. package/docs/docs/cmd/spo/{tenant/tenant-site-membership-list.mdx → site/site-membership-list.mdx} +5 -5
  86. package/docs/docs/cmd/spo/{tenant/tenant-site-rename.mdx → site/site-rename.mdx} +7 -7
  87. package/docs/docs/cmd/spo/{tenant/tenant-site-unarchive.mdx → site/site-unarchive.mdx} +4 -4
  88. package/docs/docs/cmd/spo/term/term-list.mdx +0 -3
  89. package/docs/docs/cmd/teams/chat/chat-member-add.mdx +2 -5
  90. package/docs/docs/cmd/viva/engage/engage-network-list.mdx +0 -3
  91. package/package.json +1 -1
  92. package/dist/m365/spo/commands/tenant/SPOTenantSitePropertiesEnumerable.js +0 -2
  93. package/dist/m365/spo/commands/tenant/TenantSiteProperties.js +0 -2
@@ -29,9 +29,6 @@ class TeamsChatMemberAddCommand extends GraphCommand {
29
29
  if (this.verbose) {
30
30
  await logger.logToStderr(`Adding member ${args.options.userId || args.options.userName} to chat with id ${args.options.chatId}...`);
31
31
  }
32
- if (args.options.includeAllHistory) {
33
- await this.warn(logger, `Parameter 'includeAllHistory' is deprecated. Please use 'withAllHistory' instead`);
34
- }
35
32
  const chatMemberAddOptions = {
36
33
  url: `${this.resource}/v1.0/chats/${args.options.chatId}/members`,
37
34
  headers: {
@@ -41,7 +38,7 @@ class TeamsChatMemberAddCommand extends GraphCommand {
41
38
  data: {
42
39
  '@odata.type': '#microsoft.graph.aadUserConversationMember',
43
40
  'user@odata.bind': `https://graph.microsoft.com/v1.0/users/${args.options.userId || formatting.encodeQueryParameter(args.options.userName)}`,
44
- visibleHistoryStartDateTime: (args.options.includeAllHistory || args.options.withAllHistory) ? '0001-01-01T00:00:00Z' : args.options.visibleHistoryStartDateTime,
41
+ visibleHistoryStartDateTime: args.options.withAllHistory ? '0001-01-01T00:00:00Z' : args.options.visibleHistoryStartDateTime,
45
42
  roles: [args.options.role || 'owner']
46
43
  }
47
44
  };
@@ -59,7 +56,6 @@ _a = TeamsChatMemberAddCommand, _TeamsChatMemberAddCommand_instances = new WeakS
59
56
  userName: typeof args.options.userName !== 'undefined',
60
57
  role: typeof args.options.role !== 'undefined',
61
58
  visibleHistoryStartDateTime: typeof args.options.visibleHistoryStartDateTime !== 'undefined',
62
- includeAllHistory: !!args.options.includeAllHistory,
63
59
  withAllHistory: !!args.options.withAllHistory
64
60
  });
65
61
  });
@@ -75,8 +71,6 @@ _a = TeamsChatMemberAddCommand, _TeamsChatMemberAddCommand_instances = new WeakS
75
71
  autocomplete: _a.roles
76
72
  }, {
77
73
  option: '--visibleHistoryStartDateTime [visibleHistoryStartDateTime]'
78
- }, {
79
- option: '--includeAllHistory'
80
74
  }, {
81
75
  option: '--withAllHistory'
82
76
  });
@@ -101,8 +95,8 @@ _a = TeamsChatMemberAddCommand, _TeamsChatMemberAddCommand_instances = new WeakS
101
95
  });
102
96
  }, _TeamsChatMemberAddCommand_initOptionSets = function _TeamsChatMemberAddCommand_initOptionSets() {
103
97
  this.optionSets.push({ options: ['userId', 'userName'] }, {
104
- options: ['visibleHistoryStartDateTime', 'includeAllHistory', 'withAllHistory'],
105
- runsWhen: (args) => args.options.visibleHistoryStartDateTime || args.options.includeAllHistory || args.options.withAllHistory
98
+ options: ['visibleHistoryStartDateTime', 'withAllHistory'],
99
+ runsWhen: (args) => args.options.visibleHistoryStartDateTime || args.options.withAllHistory
106
100
  });
107
101
  };
108
102
  TeamsChatMemberAddCommand.roles = ['owner', 'guest'];
@@ -24,9 +24,6 @@ class VivaEngageNetworkListCommand extends VivaEngageCommand {
24
24
  __classPrivateFieldGet(this, _VivaEngageNetworkListCommand_instances, "m", _VivaEngageNetworkListCommand_initOptions).call(this);
25
25
  }
26
26
  async commandAction(logger, args) {
27
- if (args.options.includeSuspended) {
28
- await this.warn(logger, `Parameter 'includeSuspended' is deprecated. Please use 'withSuspended' instead`);
29
- }
30
27
  const requestOptions = {
31
28
  url: `${this.resource}/v1/networks/current.json`,
32
29
  headers: {
@@ -35,7 +32,7 @@ class VivaEngageNetworkListCommand extends VivaEngageCommand {
35
32
  },
36
33
  responseType: 'json',
37
34
  data: {
38
- includeSuspended: (args.options.includeSuspended !== undefined && args.options.includeSuspended !== false) || (args.options.withSuspended !== undefined && args.options.withSuspended !== false)
35
+ includeSuspended: (args.options.withSuspended !== undefined && args.options.withSuspended !== false)
39
36
  }
40
37
  };
41
38
  try {
@@ -50,14 +47,11 @@ class VivaEngageNetworkListCommand extends VivaEngageCommand {
50
47
  _VivaEngageNetworkListCommand_instances = new WeakSet(), _VivaEngageNetworkListCommand_initTelemetry = function _VivaEngageNetworkListCommand_initTelemetry() {
51
48
  this.telemetry.push((args) => {
52
49
  Object.assign(this.telemetryProperties, {
53
- includeSuspended: args.options.includeSuspended,
54
50
  withSuspended: args.options.withSuspended
55
51
  });
56
52
  });
57
53
  }, _VivaEngageNetworkListCommand_initOptions = function _VivaEngageNetworkListCommand_initOptions() {
58
54
  this.options.unshift({
59
- option: '--includeSuspended'
60
- }, {
61
55
  option: '--withSuspended'
62
56
  });
63
57
  };
@@ -19,7 +19,7 @@ export const entraAdministrativeUnit = {
19
19
  }
20
20
  }
21
21
  const queryString = queryParameters.length > 0
22
- ? `?${queryParameters.join('&')}`
22
+ ? `&${queryParameters.join('&')}`
23
23
  : '';
24
24
  const graphResource = 'https://graph.microsoft.com';
25
25
  const administrativeUnits = await odata.getAllItems(`${graphResource}/v1.0/directory/administrativeUnits?$filter=displayName eq '${formatting.encodeQueryParameter(displayName)}'${queryString}`);
@@ -14,28 +14,21 @@ m365 entra group member add [options]
14
14
 
15
15
  ```md definition-list
16
16
  `-i, --groupId [groupId]`
17
- : The ID of the Microsoft Entra group. Specify `groupId`, `groupDisplayName` or `groupName` but not multiple.
18
-
19
- `-n, --groupDisplayName [groupDisplayName]`
20
- : (deprecated. Use option `groupName` instead) The display name of the Microsoft Entra group. Specify `groupId`, `groupDisplayName` or `groupName` but not multiple.
21
-
22
- `--groupName [groupName]`
23
- : The display name of the Microsoft Entra group. Specify `groupId`, `groupDisplayName` or `groupName` but not multiple.
24
-
25
- `--ids [ids]`
26
- : (deprecated. Use option `userIds` instead) Microsoft Entra IDs of users. You can also pass a comma-separated list of IDs. Specify either `ids`, `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
17
+ : The ID of the Microsoft Entra group. Specify `groupId` or `groupName` but not both.
27
18
 
19
+ `-n, --groupName [groupName]`
20
+ : The display name of the Microsoft Entra group. Specify `groupId` or `groupName` but not both.
28
21
  `--userIds [userIds]`
29
- : Microsoft Entra IDs of users. You can also pass a comma-separated list of IDs. Specify either `ids`, `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
22
+ : Microsoft Entra IDs of users. You can also pass a comma-separated list of IDs. Specify either `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
30
23
 
31
24
  `--userNames [userNames]`
32
- : The user principal names of users. You can also pass a comma-separated list of UPNs. Specify either `ids`, `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
25
+ : The user principal names of users. You can also pass a comma-separated list of UPNs. Specify either `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
33
26
 
34
27
  `--subgroupIds [subgroupIds]`
35
- : Comma-separated list of Microsoft Entra group IDs to add. Specify either `ids`, `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
28
+ : Comma-separated list of Microsoft Entra group IDs to add. Specify either `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
36
29
 
37
30
  `--subgroupNames [subgroupNames]`
38
- : Comma-separated list of Microsoft Entra group titles to add. Specify either `ids`, `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
31
+ : Comma-separated list of Microsoft Entra group titles to add. Specify either `userIds`,`userNames`, `subgroupIds`, or `subgroupNames` but not multiple.
39
32
 
40
33
  `-r, --role <role>`
41
34
  : The role to be assigned to the new users. Valid values: `Owner`, `Member`.
@@ -45,12 +38,6 @@ m365 entra group member add [options]
45
38
 
46
39
  ## Examples
47
40
 
48
- Add a single member specified by ID as a member to a group specified by display name.
49
-
50
- ```sh
51
- m365 entra group member add --groupDisplayName Developers --userIds 098b9f52-f48c-4401-819f-29c33794c3f5 --role Member
52
- ```
53
-
54
41
  Add a single member specified by ID as a member to a group specified by group name.
55
42
 
56
43
  ```sh
@@ -63,12 +50,6 @@ Add multiple members specified by ID as members to a group specified by ID.
63
50
  m365 entra group member add --groupId a03c0c35-ef9a-419b-8cab-f89e0a8d2d2a --userIds "098b9f52-f48c-4401-819f-29c33794c3f5,f1e06e31-3abf-4746-83c2-1513d71f38b8" --role Member
64
51
  ```
65
52
 
66
- Add a single member specified by UPN as an owner to a group specified by display name.
67
-
68
- ```sh
69
- m365 entra group member add --groupDisplayName Developers --userNames john.doe@contoso.com --role Owner
70
- ```
71
-
72
53
  Add a single member specified by UPN as an owner to a group specified by group name.
73
54
 
74
55
  ```sh
@@ -14,22 +14,16 @@ m365 entra group member set [options]
14
14
 
15
15
  ```md definition-list
16
16
  `-i, --groupId [groupId]`
17
- : The ID of the Entra ID group. Specify `groupId`, `groupDisplayName` or `groupName` but not multiple.
17
+ : The ID of the Entra ID group. Specify `groupId`, or `groupName` but not both.
18
18
 
19
- `-n, --groupDisplayName [groupDisplayName]`
20
- : (deprecated. Use option `groupName` instead) The display name of the Entra ID group. Specify `groupId`, `groupDisplayName` or `groupName` but not multiple.
21
-
22
- `--groupName [groupName]`
23
- : The display name of the Microsoft Entra group. Specify `groupId`, `groupDisplayName` or `groupName` but not multiple.
24
-
25
- `--ids [ids]`
26
- : (deprecated. Use option `userIds` instead) Comma-separated list of user IDs. Specify either `ids`, `userIds` or `userNames` but not multiple.
19
+ `-n, --groupName [groupName]`
20
+ : The display name of the Microsoft Entra group. Specify `groupId`, `groupName` but not both.
27
21
 
28
22
  `--userIds [userIds]`
29
- : Comma-separated list of user IDs. Specify either `ids`, `userIds` or `userNames` but not multiple.
23
+ : Comma-separated list of user IDs. Specify either `userIds` or `userNames` but not multiple.
30
24
 
31
25
  `--userNames [userNames]`
32
- : The user principal names of users. You can also pass a comma-separated list of UPNs. Specify either `ids` or `userNames` but not both.
26
+ : The user principal names of users. You can also pass a comma-separated list of UPNs. Specify either `userIds` or `userNames` but not both.
33
27
 
34
28
  `-r, --role <role>`
35
29
  : The new role to be assigned to the members. Valid values: `Owner`, `Member`.
@@ -39,12 +33,6 @@ m365 entra group member set [options]
39
33
 
40
34
  ## Examples
41
35
 
42
- Update a single member specified by ID to a member of a group specified by display name
43
-
44
- ```sh
45
- m365 entra group member set --groupDisplayName Developers --userIds 098b9f52-f48c-4401-819f-29c33794c3f5 --role Member
46
- ```
47
-
48
36
  Update a single member specified by ID to a member of a group specified by group name
49
37
 
50
38
  ```sh
@@ -57,12 +45,6 @@ Update multiple members specified by ID to members of a group specified by ID
57
45
  m365 entra group member set --groupId a03c0c35-ef9a-419b-8cab-f89e0a8d2d2a --userIds "098b9f52-f48c-4401-819f-29c33794c3f5,f1e06e31-3abf-4746-83c2-1513d71f38b8" --role Member
58
46
  ```
59
47
 
60
- Update a single member specified by UPN to an owner of a group specified by display name
61
-
62
- ```sh
63
- m365 entra group member set --groupDisplayName Developers --userNames john.doe@contoso.com --role Owner
64
- ```
65
-
66
48
  Update a single member specified by UPN to an owner of a group specified by group name
67
49
 
68
50
  ```sh
@@ -21,9 +21,6 @@ m365 entra m365group get [options]
21
21
  `-n, --displayName [displayName]`
22
22
  : Display name of the Microsoft 365 Group or Microsoft Teams team to retrieve information for. Specify either `id` or `displayName`, but not both.
23
23
 
24
- `--includeSiteUrl`
25
- : (deprecated. Use option `withSiteUrl` instead) Set to retrieve the site URL for the group.
26
-
27
24
  `--withSiteUrl`
28
25
  : Set to retrieve the site URL for the group.
29
26
  ```
@@ -21,9 +21,6 @@ m365 entra m365group list [options]
21
21
  `-m, --mailNickname [displayName]`
22
22
  : Retrieve only groups with mailNickname starting with the specified value.
23
23
 
24
- `--includeSiteUrl`
25
- : (deprecated. Use option `withSiteUrl` instead) Set to retrieve the site URL for each group.
26
-
27
24
  `--withSiteUrl`
28
25
  : Set to retrieve the site URL for each group.
29
26
 
@@ -27,9 +27,6 @@ m365 entra pim role assignment eligibility list [options]
27
27
  `--groupName [groupName]`
28
28
  : Display name of the group for which to list eligible roles. Specify either `userId`, `userName`, `groupId` or `groupName`. If not specified, all eligible roles will be listed.
29
29
 
30
- `--includePrincipalDetails`
31
- : (deprecated. Use option `withPrincipalDetails` instead) An optional flag to include details of the principals that were eligible for a role.
32
-
33
30
  `--withPrincipalDetails`
34
31
  : An optional flag to include details of the principals that were eligible for a role.
35
32
  ```
@@ -30,9 +30,6 @@ m365 entra pim role assignment list [options]
30
30
  `-s, --startDateTime [startDateTime]`
31
31
  : An optional ISO 8601 formatted date filter to search from.
32
32
 
33
- `--includePrincipalDetails`
34
- : (deprecated. Use option `withPrincipalDetails` instead) An optional flag to include details of the principals that were assigned a role.
35
-
36
33
  `--withPrincipalDetails`
37
34
  : An optional flag to include details of the principals that were assigned a role.
38
35
  ```
@@ -33,9 +33,6 @@ m365 entra pim role request list [options]
33
33
  `-s, --status [status]`
34
34
  : An optional value to filter the list of requests. Allowed values are: `Canceled`, `Denied`, `Failed`, `Granted`, `PendingAdminDecision`, `PendingApproval`, `PendingProvisioning`, `PendingScheduleCreation`, `Provisioned`, `Revoked`, and `ScheduleCreated`.
35
35
 
36
- `--includePrincipalDetails`
37
- : (deprecated. Use option `withPrincipalDetails` instead) An optional flag to include details of the principals that were assigned a role.
38
-
39
36
  `--withPrincipalDetails`
40
37
  : An optional flag to include details of the principals that were assigned a role.
41
38
  ```
@@ -0,0 +1,163 @@
1
+ import Global from '/docs/cmd/_global.mdx';
2
+ import Tabs from '@theme/Tabs';
3
+ import TabItem from '@theme/TabItem';
4
+
5
+ # entra roleassignment add
6
+
7
+ Assign a Entra ID role to a user and specify the scope for which the user has been granted access
8
+
9
+ ## Usage
10
+
11
+ ```sh
12
+ m365 entra roleassignment add [options]
13
+ ```
14
+
15
+ ## Options
16
+
17
+ ```md definition-list
18
+ `--roleDefinitionId [roleDefinitionId]`
19
+ : Id of a role to be assigned. Specify either `roleDefinitionId` or `roleDefinitionName`, but not both.
20
+
21
+ `--roleDefinitionName [roleDefinitionName]`
22
+ : Name of a role to be assigned. Specify either `roleDefinitionId` or `roleDefinitionName`, but not both.
23
+
24
+ `--principal <principal>`
25
+ : Id of a user, group or service principal or user principal name or group mail nickname to which the assignment is granted.
26
+
27
+ `--userId [userId]`
28
+ : Id of a user to which the assignment is scoped.
29
+
30
+ `--userName [userName]`
31
+ : User principal name of a user to which the assignment is scoped.
32
+
33
+ `--administrativeUnitId [administrativeUnitId]`
34
+ : Id of an administrative unit to which the assignment is scoped.
35
+
36
+ `--administrativeUnitName [administrativeUnitName]`
37
+ : Name of an administrative unit to which the assignment is scoped.
38
+
39
+ `--applicationId [applicationId]`
40
+ : Id of an application to which the assignment is scoped.
41
+
42
+ `applicationObjectId [applicationObjectId]`
43
+ : Object Id of an application to which the assignment is scoped.
44
+
45
+ `--applicationName [applicationName]`
46
+ : Name of an application to which the assignment is scoped.
47
+
48
+ `--servicePrincipalId [servicePrincipalId]`
49
+ : Id of a service principal to which the assignment is scoped.
50
+
51
+ `--servicePrincipalName [servicePrincipalName]`
52
+ : Name of a service principal to which the assignment is scoped.
53
+
54
+ `--groupId [groupId]`
55
+ : Id of a group to which the assignment is scoped.
56
+
57
+ `--groupName [groupName]`
58
+ : Name of a group to which the assignment is scoped.
59
+ ```
60
+
61
+ <Global />
62
+
63
+ ## Permissions
64
+
65
+ <Tabs>
66
+ <TabItem value="Delegated">
67
+
68
+ | Resource | Permissions |
69
+ |-----------------|------------------------------------|
70
+ | Microsoft Graph | RoleManagement.ReadWrite.Directory |
71
+
72
+ </TabItem>
73
+ <TabItem value="Application">
74
+
75
+ | Resource | Permissions |
76
+ |-----------------|------------------------------------|
77
+ | Microsoft Graph | RoleManagement.ReadWrite.Directory |
78
+
79
+ </TabItem>
80
+ </Tabs>
81
+
82
+ ## Examples
83
+
84
+ Assign a role specified by name to a user specified by id and scope the assignment to the whole tenant
85
+
86
+ ```sh
87
+ m365 entra roleassignment add --roleDefinitionName 'SharePoint Administrator' --principal 7a2ca997-9461-402e-9882-58088a370889
88
+ ```
89
+
90
+ Assign a role specified by id to a user specified by UPN and scope the assignment to a service principal specified by id
91
+
92
+ ```sh
93
+ m365 entra roleassignment add --roleDefinitionId 777b752-f9b7-4205-a2b1-5db0d6a0ccfc --principal john.doe@contoso.com --servicePrincipalId a4738dd8-fc0f-4646-87fb-47539f5c651b
94
+ ```
95
+
96
+ Assign a role specified by name to a group specified by mail nickname and scope the assignment to an administrative unit specified by name
97
+
98
+ ```sh
99
+ m365 entra roleassignment add --roleDefinitionName 'User Administrator' --principal 'contoso-group' --administrativeUnitName 'Marketing'
100
+ ```
101
+
102
+ Assign a role specified by name to a service principal specified by id and scope the assignment to an application specified by id
103
+
104
+ ```sh
105
+ m365 entra roleassignment add --roleDefinitionName 'Application Administrator' --principal ab2ca997-9461-402e-9882-58088a370889 --applicationId 47539fd8-fc0f-4646-87fb-a4738d5c651b
106
+ ```
107
+
108
+ ## Response
109
+
110
+ <Tabs>
111
+ <TabItem value="JSON">
112
+
113
+ ```json
114
+ {
115
+ "id": "s4awkmfj8k64aR3hKPuYbhaRP4kk4MZLjphUwkUSlIU-1",
116
+ "principalId": "3844129d-f748-4c03-8165-4412ee9b4ceb",
117
+ "directoryScopeId": "/",
118
+ "roleDefinitionId": "92b086b3-e367-4ef2-b869-1de128fb986e"
119
+ }
120
+ ```
121
+
122
+ </TabItem>
123
+ <TabItem value="Text">
124
+
125
+ ```text
126
+ directoryScopeId: /
127
+ id : s4awkmfj8k64aR3hKPuYbhaRP4kk4MZLjphUwkUSlIU-1
128
+ principalId : 3844129d-f748-4c03-8165-4412ee9b4ceb
129
+ roleDefinitionId: 92b086b3-e367-4ef2-b869-1de128fb986e
130
+ ```
131
+
132
+ </TabItem>
133
+ <TabItem value="CSV">
134
+
135
+ ```csv
136
+ id,principalId,directoryScopeId,roleDefinitionId
137
+ s4awkmfj8k64aR3hKPuYbhaRP4kk4MZLjphUwkUSlIU-1,3844129d-f748-4c03-8165-4412ee9b4ceb,/,92b086b3-e367-4ef2-b869-1de128fb986e
138
+ ```
139
+
140
+ </TabItem>
141
+ <TabItem value="Markdown">
142
+
143
+ ```md
144
+ # entra roleassignment add --roleDefinitionId "92b086b3-e367-4ef2-b869-1de128fb986e" --principal "3844129d-f748-4c03-8165-4412ee9b4ceb"
145
+
146
+ Date: 7/3/2025
147
+
148
+ ## s4awkmfj8k64aR3hKPuYbhaRP4kk4MZLjphUwkUSlIU-1
149
+
150
+ Property | Value
151
+ ---------|-------
152
+ id | s4awkmfj8k64aR3hKPuYbhaRP4kk4MZLjphUwkUSlIU-1
153
+ principalId | 3844129d-f748-4c03-8165-4412ee9b4ceb
154
+ directoryScopeId | /
155
+ roleDefinitionId | 92b086b3-e367-4ef2-b869-1de128fb986e
156
+ ```
157
+
158
+ </TabItem>
159
+ </Tabs>
160
+
161
+ ## More information
162
+
163
+ - https://learn.microsoft.com/graph/api/rbacapplication-post-roleassignments
@@ -16,7 +16,10 @@ m365 flow environment get [options]
16
16
 
17
17
  ```md definition-list
18
18
  `-n, --name [name]`
19
- : The name of the environment to get information about. When not specified, the default environment is retrieved.
19
+ : The name of the environment to get information about. When not specified, the default environment is retrieved. Specify either `name` or `default`, but not both.
20
+
21
+ `--default`
22
+ : Indicates that the default environment should be retrieved. Specify either `name` or `default`, but not both.
20
23
  ```
21
24
 
22
25
  <Global />
@@ -42,13 +45,11 @@ m365 flow environment get --name Default-d87a7535-dd31-4437-bfe1-95340acd55c5
42
45
  Get information about the default Microsoft Flow environment.
43
46
 
44
47
  ```sh
45
- m365 flow environment get
48
+ m365 flow environment get --default
46
49
  ```
47
50
 
48
51
  ## Response
49
52
 
50
- ### Standard response
51
-
52
53
  <Tabs>
53
54
  <TabItem value="JSON">
54
55
 
@@ -153,7 +154,7 @@ m365 flow environment get
153
154
  <TabItem value="Markdown">
154
155
 
155
156
  ```md
156
- # flow environment get
157
+ # flow environment get --default
157
158
 
158
159
  Date: 8/2/2023
159
160
 
@@ -21,9 +21,6 @@ m365 flow list [options]
21
21
  `--sharingStatus [sharingStatus]`
22
22
  : List a specific type of flows. Valid values: `ownedByMe`, `personal`, `sharedWithMe`, `all`. Defaults to `ownedByMe`. Don't specify this option when using asAdmin.
23
23
 
24
- `--includeSolutions`
25
- : (deprecated. Use option `withSolutions` instead) Include flows from solutions.
26
-
27
24
  `--withSolutions`
28
25
  : Include flows from solutions.
29
26
 
@@ -24,9 +24,6 @@ m365 flow run get [options]
24
24
  `-e, --environmentName <environmentName>`
25
25
  : The name of the environment where the flow is located.
26
26
 
27
- `--includeTriggerInformation`
28
- : (deprecated. Use option `withTrigger` instead) If specified, include information about the trigger details.
29
-
30
27
  `--withTrigger`
31
28
  : If specified, include information about the trigger details.
32
29
 
@@ -39,9 +39,6 @@ m365 graph subscription add [options]
39
39
  `--latestTLSVersion [latestTLSVersion]`
40
40
  : The latest version of TLS that the notification endpoint supports. Allowed values are `v1_0`, `v1_1`, `v1_2`, `v1_3`. Default is `v1_2`.
41
41
 
42
- `--includeResourceData`
43
- : (deprecated. Use option `withResourceData` instead) When set, the change notifications will include the changed resource data.
44
-
45
42
  `--withResourceData`
46
43
  : When set, the change notifications will include the changed resource data.
47
44
 
@@ -16,7 +16,10 @@ m365 pa environment get [options]
16
16
 
17
17
  ```md definition-list
18
18
  `-n, --name [name]`
19
- : The name of the environment. When not specified, the default environment is retrieved.
19
+ : The name of the environment. When not specified, the default environment is retrieved. Specify either `name` or `default`, but not both.
20
+
21
+ `--default`
22
+ : Indicates that the default environment should be retrieved. Specify either `name` or `default`, but not both.
20
23
  ```
21
24
 
22
25
  <Global />
@@ -36,7 +39,7 @@ If the environment with the name you specified doesn't exist, you will get the `
36
39
  Get information about the default Power Apps environment.
37
40
 
38
41
  ```sh
39
- m365 pa environment get
42
+ m365 pa environment get --default
40
43
  ```
41
44
 
42
45
  Get information about the Power Apps environment with the specified name.
@@ -12,12 +12,6 @@ Get information about the specified copilot
12
12
  m365 pp copilot get [options]
13
13
  ```
14
14
 
15
- ## Alias
16
-
17
- ```sh
18
- m365 pp chatbot get [options]
19
- ```
20
-
21
15
  ## Options
22
16
 
23
17
  ```md definition-list
@@ -12,12 +12,6 @@ Lists Microsoft Power Platform copilots in the specified Power Platform environm
12
12
  m365 pp copilot list [options]
13
13
  ```
14
14
 
15
- ## Alias
16
-
17
- ```sh
18
- m365 pp chatbot list [options]
19
- ```
20
-
21
15
  ## Options
22
16
 
23
17
  ```md definition-list
@@ -10,12 +10,6 @@ Removes the specified copilot
10
10
  m365 pp copilot remove [options]
11
11
  ```
12
12
 
13
- ## Alias
14
-
15
- ```sh
16
- m365 pp chatbot remove [options]
17
- ```
18
-
19
13
  ## Options
20
14
 
21
15
  ```md definition-list
@@ -16,7 +16,10 @@ m365 pp environment get [options]
16
16
 
17
17
  ```md definition-list
18
18
  `-n, --name [name]`
19
- : The name of the environment. When not specified, the default environment is retrieved.
19
+ : The name of the environment. When not specified, the default environment is retrieved. Specify either `name` or `default`, but not both.
20
+
21
+ `--default`
22
+ : Indicates that the default environment should be retrieved. Specify either `name` or `default`, but not both.
20
23
 
21
24
  `--asAdmin`
22
25
  : Run the command as admin and retrieve details of environments you do not have explicitly assigned permissions to.
@@ -53,7 +56,7 @@ m365 pp environment get --name Default-d87a7535-dd31-4437-bfe1-95340acd55c5 --as
53
56
  Get information about the default Power Platform environment.
54
57
 
55
58
  ```sh
56
- m365 pp environment get
59
+ m365 pp environment get --default
57
60
  ```
58
61
 
59
62
  ## Response
@@ -18,9 +18,6 @@ m365 pp solution publisher list [options]
18
18
  `-e, --environmentName <environmentName>`
19
19
  : The name of the environment.
20
20
 
21
- `--includeMicrosoftPublishers`
22
- : (deprecated. Use option `withMicrosoftPublishers` instead) Include the Microsoft Publishers.
23
-
24
21
  `--withMicrosoftPublishers`
25
22
  : Include the Microsoft Publishers.
26
23
 
@@ -18,9 +18,6 @@ m365 purview threatassessment get [options]
18
18
  `-i, --id <id>`
19
19
  : The Id of the threat assessment.
20
20
 
21
- `--includeResults`
22
- : (deprecated. Use option `withResults` instead) Include the threat assessment results.
23
-
24
21
  `--withResults`
25
22
  : Include the threat assessment results.
26
23
  ```
@@ -22,13 +22,26 @@ m365 spfx project upgrade [options]
22
22
  : The package manager you use. Supported managers `npm`, `pnpm`, `yarn`. Default `npm`
23
23
 
24
24
  `--shell [shell]`
25
- : The shell you use. Supported shells `bash`, `powershell`, `cmd`. Default `bash`
25
+ : The shell you use. Supported shells `bash`, `powershell`, `cmd`. Default `powershell`
26
26
 
27
27
  `--preview`
28
28
  : Upgrade project to the latest SPFx preview version
29
- ```
30
29
 
31
- <Global />
30
+ `-h, --help [help]`
31
+ : Output usage information. Optionally, specify which section of command's help you want to see. Allowed values are `options`, `examples`, `remarks`, `permissions`, `response`, `full`. Default is `options`.
32
+
33
+ `--query [query]`
34
+ : JMESPath query string. See [http://jmespath.org/](http://jmespath.org/) for more information and examples.
35
+
36
+ `-o, --output [output]`
37
+ : Output type. `json`, `text`, `csv`, `md`, `tour`, `none`. Default `json`.
38
+
39
+ `--verbose`
40
+ : Runs command with verbose logging.
41
+
42
+ `--debug`
43
+ : Runs command with debug logging.
44
+ ```
32
45
 
33
46
  ## Remarks
34
47
 
@@ -83,7 +96,7 @@ m365 spfx project upgrade --output text
83
96
  Get instructions to upgrade the current SharePoint Framework project to the latest SharePoint Framework version supported by the CLI for Microsoft 365 using PowerShell
84
97
 
85
98
  ```sh
86
- m365 spfx project upgrade --shell powershell --output text
99
+ m365 spfx project upgrade --output text
87
100
  ```
88
101
 
89
102
  Get instructions to upgrade the current SharePoint Framework project to the latest version of SharePoint Framework and save the findings in a [CodeTour](https://aka.ms/codetour) file
@@ -134,7 +147,7 @@ When upgrading an SPFx project built using version 1.15.0 to SPFx version 1.15.2
134
147
  <TabItem value="Text">
135
148
 
136
149
  ```text
137
- Execute in bash
150
+ Execute in powershell
138
151
  -----------------------
139
152
  npm i -SE @microsoft/sp-core-library@1.15.2
140
153
 
@@ -33,9 +33,6 @@ m365 spo file move [options]
33
33
  `--nameConflictBehavior [nameConflictBehavior]`
34
34
  : Behavior when a file or folder with the same name is already present at the destination. Allowed values: `fail`, `replace`, `rename`. Defaults to `fail`.
35
35
 
36
- `--includeItemPermissions`
37
- : (deprecated. Use option `withItemPermissions` instead) Ensure that item-level permissions are preserved during the move.
38
-
39
36
  `--withItemPermissions`
40
37
  : Ensure that item-level permissions are preserved during the move.
41
38