@pnp/cli-microsoft365 5.2.0-beta.dc50ce6 → 5.3.0-beta.24cd8e4

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 (56) hide show
  1. package/.eslintrc.js +1 -0
  2. package/dist/m365/aad/commands/approleassignment/approleassignment-list.js +55 -22
  3. package/dist/m365/aad/commands.js +1 -1
  4. package/dist/m365/app/commands/app-open.js +64 -0
  5. package/dist/m365/app/commands.js +1 -0
  6. package/dist/m365/planner/commands/bucket/bucket-add.js +5 -0
  7. package/dist/m365/planner/commands/bucket/bucket-get.js +203 -0
  8. package/dist/m365/planner/commands/bucket/bucket-list.js +6 -1
  9. package/dist/m365/planner/commands/bucket/bucket-remove.js +219 -0
  10. package/dist/m365/planner/commands/bucket/bucket-set.js +213 -0
  11. package/dist/m365/planner/commands/plan/plan-add.js +6 -1
  12. package/dist/m365/planner/commands/plan/plan-details-get.js +6 -1
  13. package/dist/m365/planner/commands/plan/plan-get.js +6 -1
  14. package/dist/m365/planner/commands/plan/plan-list.js +6 -1
  15. package/dist/m365/planner/commands/task/task-add.js +5 -0
  16. package/dist/m365/planner/commands/task/task-details-get.js +6 -0
  17. package/dist/m365/planner/commands/task/task-get.js +156 -7
  18. package/dist/m365/planner/commands/task/task-list.js +6 -1
  19. package/dist/m365/planner/commands/task/task-set.js +6 -1
  20. package/dist/m365/planner/commands.js +3 -0
  21. package/dist/m365/spfx/commands/project/project-upgrade/{upgrade-1.15.0-beta.1.js → upgrade-1.15.0-beta.6.js} +27 -27
  22. package/dist/m365/spfx/commands/project/project-upgrade.js +1 -1
  23. package/dist/m365/spfx/commands/spfx-doctor.js +1 -105
  24. package/dist/m365/spo/commands/field/field-list.js +84 -0
  25. package/dist/m365/spo/commands/list/list-roleinheritance-break.js +84 -0
  26. package/dist/m365/spo/commands/list/list-roleinheritance-reset.js +76 -0
  27. package/dist/m365/spo/commands/listitem/listitem-roleinheritance-break.js +83 -0
  28. package/dist/m365/spo/commands/listitem/listitem-roleinheritance-reset.js +79 -0
  29. package/dist/m365/spo/commands/roledefinition/roledefinition-list.js +49 -0
  30. package/dist/m365/spo/commands.js +6 -0
  31. package/dist/m365/teams/commands/channel/channel-member-remove.js +214 -0
  32. package/dist/m365/teams/commands.js +2 -0
  33. package/dist/m365/tenant/commands/security/security-alerts-list.js +71 -0
  34. package/dist/m365/tenant/commands.js +1 -0
  35. package/dist/utils/accessToken.js +18 -0
  36. package/docs/docs/cmd/app/app-open.md +45 -0
  37. package/docs/docs/cmd/planner/bucket/bucket-get.md +57 -0
  38. package/docs/docs/cmd/planner/bucket/bucket-remove.md +60 -0
  39. package/docs/docs/cmd/planner/bucket/bucket-set.md +57 -0
  40. package/docs/docs/cmd/planner/task/task-get.md +30 -3
  41. package/docs/docs/cmd/planner/task/task-set.md +2 -2
  42. package/docs/docs/cmd/spfx/project/project-upgrade.md +1 -1
  43. package/docs/docs/cmd/spfx/spfx-doctor.md +1 -1
  44. package/docs/docs/cmd/spo/field/field-list.md +51 -0
  45. package/docs/docs/cmd/spo/list/list-roleinheritance-break.md +55 -0
  46. package/docs/docs/cmd/spo/list/list-roleinheritance-reset.md +36 -0
  47. package/docs/docs/cmd/spo/listitem/listitem-list.md +2 -2
  48. package/docs/docs/cmd/spo/listitem/listitem-roleinheritance-break.md +58 -0
  49. package/docs/docs/cmd/spo/listitem/listitem-roleinheritance-reset.md +39 -0
  50. package/docs/docs/cmd/spo/roledefinition/roledefinition-list.md +24 -0
  51. package/docs/docs/cmd/teams/channel/channel-member-list.md +4 -4
  52. package/docs/docs/cmd/teams/channel/channel-member-remove.md +57 -0
  53. package/docs/docs/cmd/teams/channel/channel-member-set.md +2 -2
  54. package/docs/docs/cmd/tenant/security/security-alerts-list.md +30 -0
  55. package/npm-shrinkwrap.json +1517 -1284
  56. package/package.json +26 -24
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const request_1 = require("../../../../request");
4
+ const utils_1 = require("../../../../utils");
5
+ const SpoCommand_1 = require("../../../base/SpoCommand");
6
+ const commands_1 = require("../../commands");
7
+ class SpoRoleDefinitionListCommand extends SpoCommand_1.default {
8
+ get name() {
9
+ return commands_1.default.ROLEDEFINITION_LIST;
10
+ }
11
+ get description() {
12
+ return 'Gets list of role definitions for the specified site';
13
+ }
14
+ defaultProperties() {
15
+ return ['Id', 'Name'];
16
+ }
17
+ commandAction(logger, args, cb) {
18
+ if (this.verbose) {
19
+ logger.logToStderr(`Getting role definitions list from ${args.options.webUrl}...`);
20
+ }
21
+ const requestOptions = {
22
+ url: `${args.options.webUrl}/_api/web/roledefinitions`,
23
+ headers: {
24
+ 'accept': 'application/json;odata=nometadata'
25
+ },
26
+ responseType: 'json'
27
+ };
28
+ request_1.default
29
+ .get(requestOptions)
30
+ .then((response) => {
31
+ logger.log(response.value);
32
+ cb();
33
+ }, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
34
+ }
35
+ options() {
36
+ const options = [
37
+ {
38
+ option: '-u, --webUrl <webUrl>'
39
+ }
40
+ ];
41
+ const parentOptions = super.options();
42
+ return options.concat(parentOptions);
43
+ }
44
+ validate(args) {
45
+ return utils_1.validation.isValidSharePointUrl(args.options.webUrl);
46
+ }
47
+ }
48
+ module.exports = new SpoRoleDefinitionListCommand();
49
+ //# sourceMappingURL=roledefinition-list.js.map
@@ -41,6 +41,7 @@ exports.default = {
41
41
  FEATURE_LIST: `${prefix} feature list`,
42
42
  FIELD_ADD: `${prefix} field add`,
43
43
  FIELD_GET: `${prefix} field get`,
44
+ FIELD_LIST: `${prefix} field list`,
44
45
  FIELD_REMOVE: `${prefix} field remove`,
45
46
  FIELD_SET: `${prefix} field set`,
46
47
  FILE_ADD: `${prefix} file add`,
@@ -95,6 +96,8 @@ exports.default = {
95
96
  LIST_LABEL_SET: `${prefix} list label set`,
96
97
  LIST_LIST: `${prefix} list list`,
97
98
  LIST_REMOVE: `${prefix} list remove`,
99
+ LIST_ROLEINHERITANCE_BREAK: `${prefix} list roleinheritance break`,
100
+ LIST_ROLEINHERITANCE_RESET: `${prefix} list roleinheritance reset`,
98
101
  LIST_SET: `${prefix} list set`,
99
102
  LIST_SITESCRIPT_GET: `${prefix} list sitescript get`,
100
103
  LIST_VIEW_GET: `${prefix} list view get`,
@@ -117,6 +120,8 @@ exports.default = {
117
120
  LISTITEM_RECORD_DECLARE: `${prefix} listitem record declare`,
118
121
  LISTITEM_RECORD_UNDECLARE: `${prefix} listitem record undeclare`,
119
122
  LISTITEM_REMOVE: `${prefix} listitem remove`,
123
+ LISTITEM_ROLEINHERITANCE_BREAK: `${prefix} listitem roleinheritance break`,
124
+ LISTITEM_ROLEINHERITANCE_RESET: `${prefix} listitem roleinheritance reset`,
120
125
  LISTITEM_SET: `${prefix} listitem set`,
121
126
  MAIL_SEND: `${prefix} mail send`,
122
127
  NAVIGATION_NODE_ADD: `${prefix} navigation node add`,
@@ -159,6 +164,7 @@ exports.default = {
159
164
  REPORT_SITEUSAGEPAGES: `${prefix} report siteusagepages`,
160
165
  REPORT_SITEUSAGESITECOUNTS: `${prefix} report siteusagesitecounts`,
161
166
  REPORT_SITEUSAGESTORAGE: `${prefix} report siteusagestorage`,
167
+ ROLEDEFINITION_LIST: `${prefix} roledefinition list`,
162
168
  SEARCH: `${prefix} search`,
163
169
  SERVICEPRINCIPAL_GRANT_ADD: `${prefix} serviceprincipal grant add`,
164
170
  SERVICEPRINCIPAL_GRANT_LIST: `${prefix} serviceprincipal grant list`,
@@ -0,0 +1,214 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const cli_1 = require("../../../../cli");
4
+ const request_1 = require("../../../../request");
5
+ const utils_1 = require("../../../../utils");
6
+ const GraphCommand_1 = require("../../../base/GraphCommand");
7
+ const commands_1 = require("../../commands");
8
+ class TeamsChannelMemberRemoveCommand extends GraphCommand_1.default {
9
+ constructor() {
10
+ super(...arguments);
11
+ this.teamId = '';
12
+ this.channelId = '';
13
+ }
14
+ get name() {
15
+ return commands_1.default.CHANNEL_MEMBER_REMOVE;
16
+ }
17
+ get description() {
18
+ return 'Updates the role of the specified member in the specified Microsoft Teams private team channel';
19
+ }
20
+ alias() {
21
+ return [commands_1.default.CONVERSATIONMEMBER_REMOVE];
22
+ }
23
+ optionSets() {
24
+ return [
25
+ ['teamId', 'teamName'],
26
+ ['channelId', 'channelName'],
27
+ ['userId', 'userName', 'id']
28
+ ];
29
+ }
30
+ getTelemetryProperties(args) {
31
+ const telemetryProps = super.getTelemetryProperties(args);
32
+ telemetryProps.teamId = typeof args.options.teamId !== 'undefined';
33
+ telemetryProps.teamName = typeof args.options.teamName !== 'undefined';
34
+ telemetryProps.channelId = typeof args.options.channelId !== 'undefined';
35
+ telemetryProps.channelName = typeof args.options.channelName !== 'undefined';
36
+ telemetryProps.userName = typeof args.options.userName !== 'undefined';
37
+ telemetryProps.userId = typeof args.options.userId !== 'undefined';
38
+ telemetryProps.id = typeof args.options.id !== 'undefined';
39
+ telemetryProps.confirm = (!(!args.options.confirm)).toString();
40
+ return telemetryProps;
41
+ }
42
+ commandAction(logger, args, cb) {
43
+ this.showDeprecationWarning(logger, commands_1.default.CONVERSATIONMEMBER_REMOVE, commands_1.default.CHANNEL_MEMBER_REMOVE);
44
+ const removeMember = () => {
45
+ this
46
+ .removeMemberFromChannel(args)
47
+ .then(cb, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
48
+ };
49
+ if (args.options.confirm) {
50
+ removeMember();
51
+ }
52
+ else {
53
+ const userName = args.options.userName || args.options.userId || args.options.id;
54
+ const teamName = args.options.teamName || args.options.teamId;
55
+ const channelName = args.options.channelName || args.options.channelId;
56
+ cli_1.Cli.prompt({
57
+ type: 'confirm',
58
+ name: 'continue',
59
+ default: false,
60
+ message: `Are you sure you want to remove the member ${userName} from the channel ${channelName} in team ${teamName}?`
61
+ }, (result) => {
62
+ if (!result.continue) {
63
+ cb();
64
+ }
65
+ else {
66
+ removeMember();
67
+ }
68
+ });
69
+ }
70
+ }
71
+ removeMemberFromChannel(args) {
72
+ return this
73
+ .getTeamId(args)
74
+ .then((teamId) => {
75
+ this.teamId = teamId;
76
+ return this.getChannelId(args);
77
+ })
78
+ .then((channelId) => {
79
+ this.channelId = channelId;
80
+ return this.getMemberId(args);
81
+ })
82
+ .then((memberId) => {
83
+ const requestOptions = {
84
+ url: `${this.resource}/v1.0/teams/${this.teamId}/channels/${this.channelId}/members/${memberId}`,
85
+ headers: {
86
+ 'accept': 'application/json;odata.metadata=none'
87
+ },
88
+ responseType: 'json'
89
+ };
90
+ return request_1.default.delete(requestOptions);
91
+ });
92
+ }
93
+ getTeamId(args) {
94
+ if (args.options.teamId) {
95
+ return Promise.resolve(args.options.teamId);
96
+ }
97
+ const requestOptions = {
98
+ url: `${this.resource}/v1.0/groups?$filter=displayName eq '${encodeURIComponent(args.options.teamName)}'`,
99
+ headers: {
100
+ accept: 'application/json;odata.metadata=none'
101
+ },
102
+ responseType: 'json'
103
+ };
104
+ return request_1.default
105
+ .get(requestOptions)
106
+ .then(response => {
107
+ const groupItem = response.value[0];
108
+ if (!groupItem) {
109
+ return Promise.reject(`The specified team does not exist in the Microsoft Teams`);
110
+ }
111
+ if (groupItem.resourceProvisioningOptions.indexOf('Team') === -1) {
112
+ return Promise.reject(`The specified team does not exist in the Microsoft Teams`);
113
+ }
114
+ if (response.value.length > 1) {
115
+ return Promise.reject(`Multiple Microsoft Teams teams with name ${args.options.teamName} found: ${response.value.map(x => x.id)}`);
116
+ }
117
+ return Promise.resolve(groupItem.id);
118
+ });
119
+ }
120
+ getChannelId(args) {
121
+ if (args.options.channelId) {
122
+ return Promise.resolve(args.options.channelId);
123
+ }
124
+ const requestOptions = {
125
+ url: `${this.resource}/v1.0/teams/${encodeURIComponent(this.teamId)}/channels?$filter=displayName eq '${encodeURIComponent(args.options.channelName)}'`,
126
+ headers: {
127
+ accept: 'application/json;odata.metadata=none'
128
+ },
129
+ responseType: 'json'
130
+ };
131
+ return request_1.default
132
+ .get(requestOptions)
133
+ .then(response => {
134
+ const channelItem = response.value[0];
135
+ if (!channelItem) {
136
+ return Promise.reject(`The specified channel does not exist in the Microsoft Teams team`);
137
+ }
138
+ return Promise.resolve(channelItem.id);
139
+ });
140
+ }
141
+ getMemberId(args) {
142
+ if (args.options.id) {
143
+ return Promise.resolve(args.options.id);
144
+ }
145
+ const requestOptions = {
146
+ url: `${this.resource}/v1.0/teams/${this.teamId}/channels/${this.channelId}/members`,
147
+ headers: {
148
+ accept: 'application/json;odata.metadata=none'
149
+ },
150
+ responseType: 'json'
151
+ };
152
+ return request_1.default
153
+ .get(requestOptions)
154
+ .then(response => {
155
+ const conversationMembers = response.value.filter(x => {
156
+ var _a, _b;
157
+ return args.options.userId && ((_a = x.userId) === null || _a === void 0 ? void 0 : _a.toLocaleLowerCase()) === args.options.userId.toLocaleLowerCase() ||
158
+ args.options.userName && ((_b = x.email) === null || _b === void 0 ? void 0 : _b.toLocaleLowerCase()) === args.options.userName.toLocaleLowerCase();
159
+ });
160
+ const conversationMember = conversationMembers[0];
161
+ if (!conversationMember) {
162
+ return Promise.reject(`The specified member does not exist in the Microsoft Teams channel`);
163
+ }
164
+ if (conversationMembers.length > 1) {
165
+ return Promise.reject(`Multiple Microsoft Teams channel members with name ${args.options.userName} found: ${response.value.map(x => x.userId)}`);
166
+ }
167
+ return Promise.resolve(conversationMember.id);
168
+ });
169
+ }
170
+ options() {
171
+ const options = [
172
+ {
173
+ option: '--teamId [teamId]'
174
+ },
175
+ {
176
+ option: '--teamName [teamName]'
177
+ },
178
+ {
179
+ option: '--channelId [channelId]'
180
+ },
181
+ {
182
+ option: '--channelName [channelName]'
183
+ },
184
+ {
185
+ option: '--userName [userName]'
186
+ },
187
+ {
188
+ option: '--userId [userId]'
189
+ },
190
+ {
191
+ option: '--id [id]'
192
+ },
193
+ {
194
+ option: '--confirm'
195
+ }
196
+ ];
197
+ const parentOptions = super.options();
198
+ return options.concat(parentOptions);
199
+ }
200
+ validate(args) {
201
+ if (args.options.teamId && !utils_1.validation.isValidGuid(args.options.teamId)) {
202
+ return `${args.options.teamId} is not a valid GUID`;
203
+ }
204
+ if (args.options.channelId && !utils_1.validation.isValidTeamsChannelId(args.options.channelId)) {
205
+ return `${args.options.channelId} is not a valid Teams Channel ID`;
206
+ }
207
+ if (args.options.userId && !utils_1.validation.isValidGuid(args.options.userId)) {
208
+ return `${args.options.userId} is not a valid GUID`;
209
+ }
210
+ return true;
211
+ }
212
+ }
213
+ module.exports = new TeamsChannelMemberRemoveCommand();
214
+ //# sourceMappingURL=channel-member-remove.js.map
@@ -13,6 +13,7 @@ exports.default = {
13
13
  CHANNEL_LIST: `${prefix} channel list`,
14
14
  CHANNEL_MEMBER_ADD: `${prefix} channel member add`,
15
15
  CHANNEL_MEMBER_LIST: `${prefix} channel member list`,
16
+ CHANNEL_MEMBER_REMOVE: `${prefix} channel member remove`,
16
17
  CHANNEL_MEMBER_SET: `${prefix} channel member set`,
17
18
  CHANNEL_REMOVE: `${prefix} channel remove`,
18
19
  CHANNEL_SET: `${prefix} channel set`,
@@ -23,6 +24,7 @@ exports.default = {
23
24
  CHAT_MESSAGE_SEND: `${prefix} chat message send`,
24
25
  CONVERSATIONMEMBER_ADD: `${prefix} conversationmember add`,
25
26
  CONVERSATIONMEMBER_LIST: `${prefix} conversationmember list`,
27
+ CONVERSATIONMEMBER_REMOVE: `${prefix} conversationmember remove`,
26
28
  FUNSETTINGS_LIST: `${prefix} funsettings list`,
27
29
  FUNSETTINGS_SET: `${prefix} funsettings set`,
28
30
  GUESTSETTINGS_LIST: `${prefix} guestsettings list`,
@@ -0,0 +1,71 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const GraphCommand_1 = require("../../../base/GraphCommand");
4
+ const request_1 = require("../../../../request");
5
+ const commands_1 = require("../../commands");
6
+ class TenantSecurityAlertsListCommand extends GraphCommand_1.default {
7
+ get name() {
8
+ return commands_1.default.SECURITY_ALERTS_LIST;
9
+ }
10
+ get description() {
11
+ return 'Gets the security alerts for a tenant';
12
+ }
13
+ getTelemetryProperties(args) {
14
+ const telemetryProps = super.getTelemetryProperties(args);
15
+ telemetryProps.vendor = typeof args.options.vendor !== 'undefined';
16
+ return telemetryProps;
17
+ }
18
+ defaultProperties() {
19
+ return ['id', 'title', 'severity'];
20
+ }
21
+ commandAction(logger, args, cb) {
22
+ this
23
+ .listAlert(args.options)
24
+ .then((res) => {
25
+ logger.log(res);
26
+ cb();
27
+ }, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
28
+ }
29
+ listAlert(options) {
30
+ let queryFilter = '';
31
+ if (options.vendor) {
32
+ let vendorName = options.vendor;
33
+ switch (options.vendor.toLowerCase()) {
34
+ case 'azure security center':
35
+ vendorName = 'ASC';
36
+ break;
37
+ case 'microsoft cloud app security':
38
+ vendorName = 'MCAS';
39
+ break;
40
+ case 'azure active directory identity protection':
41
+ vendorName = 'IPC';
42
+ }
43
+ queryFilter = `?$filter=vendorInformation/provider eq '${encodeURIComponent(vendorName)}'`;
44
+ }
45
+ const requestOptions = {
46
+ url: `${this.resource}/v1.0/security/alerts${queryFilter}`,
47
+ headers: {
48
+ accept: 'application/json;odata.metadata=none'
49
+ },
50
+ responseType: 'json'
51
+ };
52
+ return request_1.default
53
+ .get(requestOptions)
54
+ .then(response => {
55
+ const alertList = response.value;
56
+ if (!alertList) {
57
+ return Promise.reject(`Error fetching security alerts`);
58
+ }
59
+ return Promise.resolve(alertList);
60
+ });
61
+ }
62
+ options() {
63
+ const options = [
64
+ { option: '--vendor [vendor]' }
65
+ ];
66
+ const parentOptions = super.options();
67
+ return options.concat(parentOptions);
68
+ }
69
+ }
70
+ module.exports = new TenantSecurityAlertsListCommand();
71
+ //# sourceMappingURL=security-alerts-list.js.map
@@ -9,6 +9,7 @@ exports.default = {
9
9
  REPORT_OFFICE365ACTIVATIONSUSERDETAIL: `${prefix} report office365activationsuserdetail`,
10
10
  REPORT_OFFICE365ACTIVATIONSUSERCOUNTS: `${prefix} report office365activationsusercounts`,
11
11
  REPORT_SERVICESUSERCOUNTS: `${prefix} report servicesusercounts`,
12
+ SECURITY_ALERTS_LIST: `${prefix} security alerts list`,
12
13
  SERVICEANNOUNCEMENT_HEALTHISSUE_GET: `${prefix} serviceannouncement healthissue get`,
13
14
  SERVICEANNOUNCEMENT_HEALTH_GET: `${prefix} serviceannouncement health get`,
14
15
  SERVICEANNOUNCEMENT_HEALTH_LIST: `${prefix} serviceannouncement health list`,
@@ -2,6 +2,24 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.accessToken = void 0;
4
4
  exports.accessToken = {
5
+ isAppOnlyAccessToken(accessToken) {
6
+ let isAppOnlyAccessToken = false;
7
+ if (!accessToken || accessToken.length === 0) {
8
+ return isAppOnlyAccessToken;
9
+ }
10
+ const chunks = accessToken.split('.');
11
+ if (chunks.length !== 3) {
12
+ return isAppOnlyAccessToken;
13
+ }
14
+ const tokenString = Buffer.from(chunks[1], 'base64').toString();
15
+ try {
16
+ const token = JSON.parse(tokenString);
17
+ isAppOnlyAccessToken = token.idtyp === 'app';
18
+ }
19
+ catch (_a) {
20
+ }
21
+ return isAppOnlyAccessToken;
22
+ },
5
23
  getTenantIdFromAccessToken(accessToken) {
6
24
  let tenantId = '';
7
25
  if (!accessToken || accessToken.length === 0) {
@@ -0,0 +1,45 @@
1
+ # aad app open
2
+
3
+ Returns deep link of the current AD app to open the Azure portal on the Azure AD app registration management page.
4
+
5
+ ## Usage
6
+
7
+ ```sh
8
+ m365 app open [options]
9
+ ```
10
+
11
+ ## Options
12
+
13
+ `--appId [appId]`
14
+ : Optional Application (client) ID of the Azure AD application registration to open. Uses the app from the `.m365rc.json` file corresponding to the `appId`. If multiple apps are available, this will evade the prompt to choose an app. If the `appId` is not available in the list of apps, an error is thrown.
15
+
16
+ `--preview`
17
+ : Use to open the url of the Azure AD preview portal.
18
+
19
+ --8<-- "docs/cmd/_global.md"
20
+
21
+ ## Remarks
22
+
23
+ If config setting `autoOpenLinksInBrowser` is configured to true, the command will automatically open the link to the Azure Portal in the browser.
24
+
25
+ Gets the app from the `.m365rc.json` file in the current directory. If the `--appId` option is not used and multiple apps are available, it will prompt the user to choose one.
26
+
27
+ ## Examples
28
+
29
+ Prints the URL to the Azure AD application registration management page on the Azure Portal.
30
+
31
+ ```sh
32
+ m365 app open
33
+ ```
34
+
35
+ Prints the url of the Azure AD application registration management page on the preview Azure Portal.
36
+
37
+ ```sh
38
+ m365 app open --preview
39
+ ```
40
+
41
+ Prints the URL to the Azure AD application registration management page on the Azure Portal, evading a possible choice prompt in the case of multiple saved apps in the `.m365rc.json` file.
42
+
43
+ ```sh
44
+ m365 app open --appId d75be2e1-0204-4f95-857d-51a37cf40be8
45
+ ```
@@ -0,0 +1,57 @@
1
+ # planner bucket get
2
+
3
+ Gets the Microsoft Planner bucket in a plan
4
+
5
+ ## Usage
6
+
7
+ ```sh
8
+ m365 planner bucket get [options]
9
+ ```
10
+
11
+ ## Options
12
+
13
+ `-i, --id [id]`
14
+ : ID of the bucket to retrieve details. Specify either `id` or `name` but not both.
15
+
16
+ `-name, --name [name]`
17
+ : Name of the bucket to retrieve details. Specify either `id` or `name` but not both.
18
+
19
+ `--planId [planId]`
20
+ : Plan ID to which the bucket belongs. Specify either `planId` or `planName` when using `name`.
21
+
22
+ `--planName [planName]`
23
+ : Plan Name to which the bucket belongs. Specify either `planId` or `planName` when using `name`.
24
+
25
+ `--ownerGroupId [ownerGroupId]`
26
+ : ID of the group to which the plan belongs. Specify `ownerGroupId` or `ownerGroupName` when using `planName`.
27
+
28
+ `--ownerGroupName [ownerGroupName]`
29
+ : Name of the group to which the plan belongs. Specify `ownerGroupId` or `ownerGroupName` when using `planName`.
30
+
31
+ --8<-- "docs/cmd/_global.md"
32
+
33
+ ## Examples
34
+
35
+ Gets the specified Microsoft Planner bucket
36
+
37
+ ```sh
38
+ m365 planner bucket get --id "5h1uuYFk4kKQ0hfoTUkRLpgALtYi"
39
+ ```
40
+
41
+ Gets the Microsoft Planner bucket in the PlanId xqQg5FS2LkCp935s-FIFm2QAFkHM
42
+
43
+ ```sh
44
+ m365 planner bucket get --name "Planner Bucket A" --planId "xqQg5FS2LkCp935s-FIFm2QAFkHM"
45
+ ```
46
+
47
+ Gets the Microsoft Planner bucket in the Plan _My Plan_ owned by group _My Group_
48
+
49
+ ```sh
50
+ m365 planner bucket get --name "Planner Bucket A" --planName "My Plan" --ownerGroupName "My Group"
51
+ ```
52
+
53
+ Gets the Microsoft Planner bucket in the Plan _My Plan_ owned by groupId ee0f40fc-b2f7-45c7-b62d-11b90dd2ea8e
54
+
55
+ ```sh
56
+ m365 planner bucket get --name "Planner Bucket A" --planName "My Plan" --ownerGroupId "ee0f40fc-b2f7-45c7-b62d-11b90dd2ea8e"
57
+ ```
@@ -0,0 +1,60 @@
1
+ # planner bucket remove
2
+
3
+ Removes the Microsoft Planner bucket from a plan
4
+
5
+ ## Usage
6
+
7
+ ```sh
8
+ m365 planner bucket remove [options]
9
+ ```
10
+
11
+ ## Options
12
+
13
+ `--id [id]`
14
+ : ID of the bucket to remove. Specify either `id` or `name` but not both.
15
+
16
+ `--name [name]`
17
+ : Name of the bucket to remove. Specify either `id` or `name` but not both.
18
+
19
+ `--planId [planId]`
20
+ : ID of the plan to which the bucket to remove belongs. Specify either `planId` or `planName` when using `name`.
21
+
22
+ `--planName [planName]`
23
+ : Name of the plan to which the bucket to remove belongs. Specify either `planId` or `planName` when using `name`.
24
+
25
+ `--ownerGroupId [ownerGroupId]`
26
+ : ID of the group to which the plan belongs. Specify either `ownerGroupId` or `ownerGroupName` when using `planName`.
27
+
28
+ `--ownerGroupName [ownerGroupName]`
29
+ : Name of the group to which the plan belongs. Specify either `ownerGroupId` or `ownerGroupName` when using `planName`.
30
+
31
+ `--confirm`
32
+ : Don't prompt for confirmation
33
+
34
+ --8<-- "docs/cmd/_global.md"
35
+
36
+ ## Examples
37
+
38
+ Removes the Microsoft Planner bucket by ID
39
+
40
+ ```sh
41
+ m365 planner bucket remove --id "vncYUXCRBke28qMLB-d4xJcACtNz"
42
+ ```
43
+
44
+ Removes the Microsoft Planner bucket by ID without confirmation
45
+
46
+ ```sh
47
+ m365 planner bucket remove --id "vncYUXCRBke28qMLB-d4xJcACtNz" --confirm
48
+ ```
49
+
50
+ Removes the Microsoft Planner bucket with name _My Bucket_ in the Plan with ID _oUHpnKBFekqfGE_PS6GGUZcAFY7b_
51
+
52
+ ```sh
53
+ m365 planner bucket remove --name "My Bucket" --planId "oUHpnKBFekqfGE_PS6GGUZcAFY7b"
54
+ ```
55
+
56
+ Removes the Microsoft Planner bucket with name _My Bucket_ in the Plan _My Plan_ owned by group _My Group_
57
+
58
+ ```sh
59
+ m365 planner bucket remove --name "My Bucket" --planName "My Plan" --ownerGroupName "My Group"
60
+ ```
@@ -0,0 +1,57 @@
1
+ # planner bucket set
2
+
3
+ Updates a Microsoft Planner bucket
4
+
5
+ ## Usage
6
+
7
+ ```sh
8
+ m365 planner bucket set [options]
9
+ ```
10
+
11
+ ## Options
12
+
13
+ `-i, --id [id]`
14
+ : ID of the bucket. Specify either `id` or `name` but not both.
15
+
16
+ `--name [name]`
17
+ : Name of the bucket. Specify either `id` or `name` but not both.
18
+
19
+ `--planId [planId]`
20
+ : ID of the plan to update the bucket of. Use when referring to bucket using `name`. Specify either `planId` or `planName` but not both.
21
+
22
+ `--planName [planName]`
23
+ : Name of the plan to update the bucket of. Use when referring to bucket using `name`. Specify either `planId` or `planName` but not both.
24
+
25
+ `--ownerGroupId [ownerGroupId]`
26
+ : ID of the group to which the plan belongs. Use when referring to plan using `planName`. Specify `ownerGroupId` or `ownerGroupName`.
27
+
28
+ `--ownerGroupName [ownerGroupName]`
29
+ : Name of the group to which the plan belongs. Use when referring to plan using `planName`. Specify `ownerGroupId` or `ownerGroupName`.
30
+
31
+ `--newName [newName]`
32
+ : New name of the bucket.
33
+
34
+ `--orderHint [orderHint]`
35
+ : Hint used to order items of this type in a list view. The format is defined as outlined [here](https://docs.microsoft.com/en-us/graph/api/resources/planner-order-hint-format?view=graph-rest-1.0).
36
+
37
+ --8<-- "docs/cmd/_global.md"
38
+
39
+ ## Examples
40
+
41
+ Updates the Microsoft Planner bucket with ID _vncYUXCRBke28qMLB-d4xJcACtNz_
42
+
43
+ ```sh
44
+ m365 planner bucket set --id "vncYUXCRBke28qMLB-d4xJcACtNz" --newName "New bucket name"
45
+ ```
46
+
47
+ Updates the Microsoft Planner bucket named _My Bucket_ in the Plan _My Plan_ owned by group _My Group_
48
+
49
+ ```sh
50
+ m365 planner bucket set --name "My Bucket" --planName "My Plan" --ownerGroupName "My Group" --newName "New bucket name"
51
+ ```
52
+
53
+ Updates the Microsoft Planner bucket named _My Bucket_ in the Plan _My Plan_ owned by group with ID _00000000-0000-0000-0000-000000000000_
54
+
55
+ ```sh
56
+ m365 planner bucket set --name "My Bucket" --planName "My Plan" --ownerGroupId 00000000-0000-0000-0000-000000000000 --newName "New bucket name"
57
+ ```