@pnp/cli-microsoft365 6.11.0-beta.7edcad2 → 6.11.0-beta.ee225fb
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.
- package/dist/m365/cli/commands/config/config-list.js +29 -0
- package/dist/m365/cli/commands.js +1 -0
- package/dist/m365/planner/commands/bucket/bucket-add.js +2 -2
- package/dist/m365/planner/commands/bucket/bucket-get.js +2 -2
- package/dist/m365/planner/commands/bucket/bucket-list.js +2 -2
- package/dist/m365/planner/commands/bucket/bucket-remove.js +2 -2
- package/dist/m365/planner/commands/bucket/bucket-set.js +2 -2
- package/dist/m365/planner/commands/plan/plan-get.js +1 -2
- package/dist/m365/planner/commands/plan/plan-list.js +4 -5
- package/dist/m365/planner/commands/plan/plan-set.js +2 -2
- package/dist/m365/spo/commands/navigation/navigation-node-set.js +2 -2
- package/dist/utils/planner.js +6 -3
- package/docs/docs/cmd/aad/user/user-set.mdx +1 -1
- package/docs/docs/cmd/cli/config/config-list.mdx +78 -0
- package/docs/docs/cmd/flow/flow-enable.mdx +2 -2
- package/docs/docs/cmd/login.mdx +6 -0
- package/docs/docs/cmd/pp/dataverse/dataverse-table-get.mdx +2 -2
- package/docs/docs/cmd/pp/dataverse/dataverse-table-list.mdx +2 -2
- package/docs/docs/cmd/pp/dataverse/dataverse-table-remove.mdx +3 -3
- package/docs/docs/cmd/spo/listitem/listitem-attachment-list.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-add.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-list.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-remove.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-commandset-add.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-commandset-remove.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-commandset-set.mdx +1 -1
- package/docs/docs/cmd/yammer/network/network-list.mdx +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
const Cli_1 = require("../../../../cli/Cli");
|
|
13
|
+
const AnonymousCommand_1 = require("../../../base/AnonymousCommand");
|
|
14
|
+
const commands_1 = require("../../commands");
|
|
15
|
+
class CliConfigListCommand extends AnonymousCommand_1.default {
|
|
16
|
+
get name() {
|
|
17
|
+
return commands_1.default.CONFIG_LIST;
|
|
18
|
+
}
|
|
19
|
+
get description() {
|
|
20
|
+
return 'List all self set CLI for Microsoft 365 configurations';
|
|
21
|
+
}
|
|
22
|
+
commandAction(logger) {
|
|
23
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
+
logger.log(Cli_1.Cli.getInstance().config.all);
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
module.exports = new CliConfigListCommand();
|
|
29
|
+
//# sourceMappingURL=config-list.js.map
|
|
@@ -8,6 +8,7 @@ exports.default = {
|
|
|
8
8
|
COMPLETION_SH_SETUP: `${prefix} completion sh setup`,
|
|
9
9
|
COMPLETION_SH_UPDATE: `${prefix} completion sh update`,
|
|
10
10
|
CONFIG_GET: `${prefix} config get`,
|
|
11
|
+
CONFIG_LIST: `${prefix} config list`,
|
|
11
12
|
CONFIG_RESET: `${prefix} config reset`,
|
|
12
13
|
CONFIG_SET: `${prefix} config set`,
|
|
13
14
|
CONSENT: `${prefix} consent`,
|
|
@@ -73,8 +73,8 @@ class PlannerBucketAddCommand extends GraphCommand_1.default {
|
|
|
73
73
|
const plan = yield planner_1.planner.getPlanByTitle(args.options.planTitle, groupId);
|
|
74
74
|
return plan.id;
|
|
75
75
|
}
|
|
76
|
-
const
|
|
77
|
-
return
|
|
76
|
+
const plan = yield planner_1.planner.getPlanByRosterId(args.options.rosterId);
|
|
77
|
+
return plan.id;
|
|
78
78
|
});
|
|
79
79
|
}
|
|
80
80
|
getGroupId(args) {
|
|
@@ -84,8 +84,8 @@ class PlannerBucketGetCommand extends GraphCommand_1.default {
|
|
|
84
84
|
const plan = yield planner_1.planner.getPlanByTitle(planTitle, groupId);
|
|
85
85
|
return plan.id;
|
|
86
86
|
}
|
|
87
|
-
const
|
|
88
|
-
return
|
|
87
|
+
const plan = yield planner_1.planner.getPlanByRosterId(rosterId);
|
|
88
|
+
return plan.id;
|
|
89
89
|
});
|
|
90
90
|
}
|
|
91
91
|
getBucketById(id) {
|
|
@@ -61,8 +61,8 @@ class PlannerBucketListCommand extends GraphCommand_1.default {
|
|
|
61
61
|
const plan = yield planner_1.planner.getPlanByTitle(args.options.planTitle, groupId);
|
|
62
62
|
return plan.id;
|
|
63
63
|
}
|
|
64
|
-
const
|
|
65
|
-
return
|
|
64
|
+
const plan = yield planner_1.planner.getPlanByRosterId(args.options.rosterId);
|
|
65
|
+
return plan.id;
|
|
66
66
|
});
|
|
67
67
|
}
|
|
68
68
|
getGroupId(args) {
|
|
@@ -114,8 +114,8 @@ class PlannerBucketRemoveCommand extends GraphCommand_1.default {
|
|
|
114
114
|
const plan = yield planner_1.planner.getPlanByTitle(planTitle, groupId);
|
|
115
115
|
return plan.id;
|
|
116
116
|
}
|
|
117
|
-
const
|
|
118
|
-
return
|
|
117
|
+
const plan = yield planner_1.planner.getPlanByRosterId(rosterId);
|
|
118
|
+
return plan.id;
|
|
119
119
|
});
|
|
120
120
|
}
|
|
121
121
|
getGroupId(args) {
|
|
@@ -105,8 +105,8 @@ class PlannerBucketSetCommand extends GraphCommand_1.default {
|
|
|
105
105
|
const plan = yield planner_1.planner.getPlanByTitle(planTitle, groupId);
|
|
106
106
|
return plan.id;
|
|
107
107
|
}
|
|
108
|
-
const
|
|
109
|
-
return
|
|
108
|
+
const plan = yield planner_1.planner.getPlanByRosterId(rosterId);
|
|
109
|
+
return plan.id;
|
|
110
110
|
});
|
|
111
111
|
}
|
|
112
112
|
getGroupId(args) {
|
|
@@ -50,8 +50,7 @@ class PlannerPlanGetCommand extends GraphCommand_1.default {
|
|
|
50
50
|
else {
|
|
51
51
|
let plan = {};
|
|
52
52
|
if (args.options.rosterId) {
|
|
53
|
-
|
|
54
|
-
plan = plans[0];
|
|
53
|
+
plan = yield planner_1.planner.getPlanByRosterId(args.options.rosterId);
|
|
55
54
|
}
|
|
56
55
|
else {
|
|
57
56
|
let groupId = undefined;
|
|
@@ -41,17 +41,16 @@ class PlannerPlanListCommand extends GraphCommand_1.default {
|
|
|
41
41
|
commandAction(logger, args) {
|
|
42
42
|
return __awaiter(this, void 0, void 0, function* () {
|
|
43
43
|
try {
|
|
44
|
-
let plannerPlans =
|
|
44
|
+
let plannerPlans = [];
|
|
45
45
|
if (args.options.ownerGroupId || args.options.ownerGroupName) {
|
|
46
46
|
const groupId = yield this.getGroupId(args);
|
|
47
47
|
plannerPlans = yield planner_1.planner.getPlansByGroupId(groupId);
|
|
48
48
|
}
|
|
49
49
|
else {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
if (plannerPlans && plannerPlans.length > 0) {
|
|
53
|
-
logger.log(plannerPlans);
|
|
50
|
+
const plan = yield planner_1.planner.getPlanByRosterId(args.options.rosterId);
|
|
51
|
+
plannerPlans.push(plan);
|
|
54
52
|
}
|
|
53
|
+
logger.log(plannerPlans);
|
|
55
54
|
}
|
|
56
55
|
catch (err) {
|
|
57
56
|
this.handleRejectedODataJsonPromise(err);
|
|
@@ -61,8 +61,8 @@ class PlannerPlanSetCommand extends GraphCommand_1.default {
|
|
|
61
61
|
}
|
|
62
62
|
let groupId = '';
|
|
63
63
|
if (args.options.rosterId) {
|
|
64
|
-
const
|
|
65
|
-
return
|
|
64
|
+
const plan = yield planner_1.planner.getPlanByRosterId(args.options.rosterId);
|
|
65
|
+
return plan.id;
|
|
66
66
|
}
|
|
67
67
|
else {
|
|
68
68
|
groupId = yield this.getGroupId(args);
|
|
@@ -132,8 +132,8 @@ _SpoNavigationNodeSetCommand_instances = new WeakSet(), _SpoNavigationNodeSetCom
|
|
|
132
132
|
if (isValidSharePointUrl !== true) {
|
|
133
133
|
return isValidSharePointUrl;
|
|
134
134
|
}
|
|
135
|
-
if (args.options.audienceIds === undefined &&
|
|
136
|
-
return `Please specify
|
|
135
|
+
if (args.options.audienceIds === undefined && args.options.url === undefined && args.options.isExternal === undefined && !args.options.title && args.options.openInNewWindow === undefined) {
|
|
136
|
+
return `Please specify at least one property to update.`;
|
|
137
137
|
}
|
|
138
138
|
if (args.options.audienceIds) {
|
|
139
139
|
const audienceIdsSplitted = args.options.audienceIds.split(',');
|
package/dist/utils/planner.js
CHANGED
|
@@ -45,11 +45,14 @@ exports.planner = {
|
|
|
45
45
|
return odata_1.odata.getAllItems(`${graphResource}/v1.0/groups/${groupId}/planner/plans`, metadata);
|
|
46
46
|
},
|
|
47
47
|
/**
|
|
48
|
-
* Get
|
|
48
|
+
* Get the Planner plan for a specific Roster.
|
|
49
49
|
* @param rosterId Roster ID.
|
|
50
50
|
*/
|
|
51
|
-
|
|
52
|
-
return
|
|
51
|
+
getPlanByRosterId(rosterId, metadata = 'none') {
|
|
52
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
53
|
+
const plans = yield odata_1.odata.getAllItems(`${graphResource}/beta/planner/rosters/${rosterId}/plans`, metadata);
|
|
54
|
+
return plans[0];
|
|
55
|
+
});
|
|
53
56
|
},
|
|
54
57
|
/**
|
|
55
58
|
* Get Planner plan by title in a specific group.
|
|
@@ -87,7 +87,7 @@ If the user with the specified ID or username doesn't exist, or if the specified
|
|
|
87
87
|
Update specific property _department_ of user with id _1caf7dcd-7e83-4c3a-94f7-932a1299c844_
|
|
88
88
|
|
|
89
89
|
```sh
|
|
90
|
-
m365 aad user set --objectId 1caf7dcd-7e83-4c3a-94f7-932a1299c844 --
|
|
90
|
+
m365 aad user set --objectId 1caf7dcd-7e83-4c3a-94f7-932a1299c844 --department IT
|
|
91
91
|
```
|
|
92
92
|
|
|
93
93
|
Update multiple properties of user by name
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import CLISettings from '/docs/_clisettings.mdx';
|
|
2
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
3
|
+
import Tabs from '@theme/Tabs';
|
|
4
|
+
import TabItem from '@theme/TabItem';
|
|
5
|
+
|
|
6
|
+
# cli config list
|
|
7
|
+
|
|
8
|
+
List all self set CLI for Microsoft 365 configurations
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```sh
|
|
13
|
+
m365 cli config list [options]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Options
|
|
17
|
+
|
|
18
|
+
<Global />
|
|
19
|
+
|
|
20
|
+
## Available settings
|
|
21
|
+
|
|
22
|
+
Following is the list of configuration settings available in CLI for Microsoft 365.
|
|
23
|
+
|
|
24
|
+
<CLISettings />
|
|
25
|
+
|
|
26
|
+
## Examples
|
|
27
|
+
|
|
28
|
+
List all self set configuration keys with their value
|
|
29
|
+
|
|
30
|
+
```sh
|
|
31
|
+
m365 cli config list
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Response
|
|
35
|
+
|
|
36
|
+
<Tabs>
|
|
37
|
+
<TabItem value="JSON">
|
|
38
|
+
|
|
39
|
+
```json
|
|
40
|
+
{
|
|
41
|
+
"errorOutput": "stdout"
|
|
42
|
+
}
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
</TabItem>
|
|
46
|
+
<TabItem value="Text">
|
|
47
|
+
|
|
48
|
+
```text
|
|
49
|
+
errorOutput: stdout
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
</TabItem>
|
|
53
|
+
<TabItem value="CSV">
|
|
54
|
+
|
|
55
|
+
```csv
|
|
56
|
+
errorOutput
|
|
57
|
+
stdout
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
</TabItem>
|
|
61
|
+
<TabItem value="Markdown">
|
|
62
|
+
|
|
63
|
+
```md
|
|
64
|
+
# cli config list
|
|
65
|
+
|
|
66
|
+
Date: 29/6/2023
|
|
67
|
+
|
|
68
|
+
Property | Value
|
|
69
|
+
---------|-------
|
|
70
|
+
errorOutput | stdout
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
</TabItem>
|
|
74
|
+
</Tabs>
|
|
75
|
+
|
|
76
|
+
## More information
|
|
77
|
+
|
|
78
|
+
- [Configuring the CLI for Microsoft 365](../../../user-guide/configuring-cli.mdx)
|
|
@@ -44,13 +44,13 @@ If the Power Automate flow with the name you specified doesn't exist, you will g
|
|
|
44
44
|
Enables Power Automate flow owned by the currently signed-in user
|
|
45
45
|
|
|
46
46
|
```sh
|
|
47
|
-
m365 flow enable --
|
|
47
|
+
m365 flow enable --environmentName Default-d87a7535-dd31-4437-bfe1-95340acd55c5 --name 3989cb59-ce1a-4a5c-bb78-257c5c39381d
|
|
48
48
|
```
|
|
49
49
|
|
|
50
50
|
Enables Power Automate flow owned by another user
|
|
51
51
|
|
|
52
52
|
```sh
|
|
53
|
-
m365 flow enable --
|
|
53
|
+
m365 flow enable --environmentName Default-d87a7535-dd31-4437-bfe1-95340acd55c5 --name 3989cb59-ce1a-4a5c-bb78-257c5c39381d --asAdmin
|
|
54
54
|
```
|
|
55
55
|
|
|
56
56
|
## Response
|
package/docs/docs/cmd/login.mdx
CHANGED
|
@@ -157,6 +157,12 @@ Log in to Microsoft 365 using your own Azure AD application that's restricted on
|
|
|
157
157
|
m365 login --appId 31359c7f-bd7e-475c-86db-fdb8c937548c --tenant 31359c7f-bd7e-475c-86db-fdb8c937548a
|
|
158
158
|
```
|
|
159
159
|
|
|
160
|
+
Log in to Microsoft 365 using your own Azure AD application and a personal information exchange (.pfx) file
|
|
161
|
+
|
|
162
|
+
```sh
|
|
163
|
+
m365 login --authType certificate --appId 31359c7f-bd7e-475c-86db-fdb8c937548c --tenant 31359c7f-bd7e-475c-86db-fdb8c937548a --certificateFile /Users/user/dev/localhost.pfx --password 'pass@word1'
|
|
164
|
+
```
|
|
165
|
+
|
|
160
166
|
Log in to Microsoft 365 using the interactive browser authentication. Uses the identity of the current user.
|
|
161
167
|
|
|
162
168
|
```sh
|
|
@@ -32,13 +32,13 @@ m365 pp dataverse table get [options]
|
|
|
32
32
|
List a table for the given environment
|
|
33
33
|
|
|
34
34
|
```sh
|
|
35
|
-
m365 pp dataverse table get
|
|
35
|
+
m365 pp dataverse table get --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339" --name "aaduser"
|
|
36
36
|
```
|
|
37
37
|
|
|
38
38
|
List a table for the given environment as Admin
|
|
39
39
|
|
|
40
40
|
```sh
|
|
41
|
-
m365 pp dataverse table get
|
|
41
|
+
m365 pp dataverse table get --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339" --name "aaduser" --asAdmin
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
## Response
|
|
@@ -29,13 +29,13 @@ m365 pp dataverse table list [options]
|
|
|
29
29
|
List all tables for the given environment
|
|
30
30
|
|
|
31
31
|
```sh
|
|
32
|
-
m365 pp dataverse table list
|
|
32
|
+
m365 pp dataverse table list --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339"
|
|
33
33
|
```
|
|
34
34
|
|
|
35
35
|
List all tables for the given environment as Admin
|
|
36
36
|
|
|
37
37
|
```sh
|
|
38
|
-
m365 pp dataverse table list
|
|
38
|
+
m365 pp dataverse table list --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339" --asAdmin
|
|
39
39
|
```
|
|
40
40
|
|
|
41
41
|
## Response
|
|
@@ -33,19 +33,19 @@ m365 pp dataverse table remove [options]
|
|
|
33
33
|
Removes a dataverse table in a given environment
|
|
34
34
|
|
|
35
35
|
```sh
|
|
36
|
-
m365 pp dataverse table remove
|
|
36
|
+
m365 pp dataverse table remove --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339" --name "aaduser"
|
|
37
37
|
```
|
|
38
38
|
|
|
39
39
|
Removes a dataverse table in a given environment as Admin
|
|
40
40
|
|
|
41
41
|
```sh
|
|
42
|
-
m365 pp dataverse table remove
|
|
42
|
+
m365 pp dataverse table remove --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339" --name "aaduser" --asAdmin
|
|
43
43
|
```
|
|
44
44
|
|
|
45
45
|
Removes a dataverse table in a given environment without prompting for confirmation
|
|
46
46
|
|
|
47
47
|
```sh
|
|
48
|
-
m365 pp dataverse table remove
|
|
48
|
+
m365 pp dataverse table remove --environment "Default-2ca3eaa5-140f-4175-8261-3272edf9f339" --name "aaduser" --confirm
|
|
49
49
|
```
|
|
50
50
|
|
|
51
51
|
## Response
|
package/package.json
CHANGED