@pnp/cli-microsoft365 5.5.0-beta.f0f7ad7 → 5.5.0-beta.f697eab
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/aad/commands/o365group/o365group-recyclebinitem-restore.js +60 -9
- package/dist/m365/spo/commands/field/field-set.js +16 -9
- package/dist/m365/spo/commands/group/group-add.js +96 -0
- package/dist/m365/spo/commands/group/group-set.js +167 -0
- package/dist/m365/spo/commands/hubsite/hubsite-get.js +38 -2
- package/dist/m365/spo/commands/site/site-classic-list.js +1 -0
- package/dist/m365/spo/commands/site/site-list.js +59 -17
- package/dist/m365/spo/commands.js +2 -0
- package/docs/docs/cmd/aad/o365group/o365group-recyclebinitem-restore.md +21 -3
- package/docs/docs/cmd/spo/field/field-set.md +7 -4
- package/docs/docs/cmd/spo/group/group-add.md +51 -0
- package/docs/docs/cmd/spo/group/group-set.md +69 -0
- package/docs/docs/cmd/spo/hubsite/hubsite-get.md +21 -0
- package/docs/docs/cmd/spo/site/site-classic-list.md +3 -0
- package/docs/docs/cmd/spo/site/site-list.md +19 -7
- package/npm-shrinkwrap.json +173 -158
- package/package.json +13 -13
|
@@ -63,9 +63,11 @@ exports.default = {
|
|
|
63
63
|
FOLDER_REMOVE: `${prefix} folder remove`,
|
|
64
64
|
FOLDER_RENAME: `${prefix} folder rename`,
|
|
65
65
|
GET: `${prefix} get`,
|
|
66
|
+
GROUP_ADD: `${prefix} group add`,
|
|
66
67
|
GROUP_GET: `${prefix} group get`,
|
|
67
68
|
GROUP_LIST: `${prefix} group list`,
|
|
68
69
|
GROUP_REMOVE: `${prefix} group remove`,
|
|
70
|
+
GROUP_SET: `${prefix} group set`,
|
|
69
71
|
GROUP_USER_ADD: `${prefix} group user add`,
|
|
70
72
|
GROUP_USER_LIST: `${prefix} group user list`,
|
|
71
73
|
GROUP_USER_REMOVE: `${prefix} group user remove`,
|
|
@@ -16,15 +16,33 @@ m365 aad o365group restore [options]
|
|
|
16
16
|
|
|
17
17
|
## Options
|
|
18
18
|
|
|
19
|
-
`-i, --id
|
|
20
|
-
: The ID of the Microsoft 365 Group to restore
|
|
19
|
+
`-i, --id [id]`
|
|
20
|
+
: The ID of the Microsoft 365 Group to restore. Specify either `id`, `displayName` or `mailNickname` but not multiple.
|
|
21
|
+
|
|
22
|
+
`-d, --displayName [displayName]`
|
|
23
|
+
: Display name for the Microsoft 365 Group to restore. Specify either `id`, `displayName` or `mailNickname` but not multiple.
|
|
24
|
+
|
|
25
|
+
`-m, --mailNickname [mailNickname]`
|
|
26
|
+
: Name of the group e-mail (part before the @). Specify either `id`, `displayName` or `mailNickname` but not multiple.
|
|
21
27
|
|
|
22
28
|
--8<-- "docs/cmd/_global.md"
|
|
23
29
|
|
|
24
30
|
## Examples
|
|
25
31
|
|
|
26
|
-
Restores the Microsoft 365 Group with
|
|
32
|
+
Restores the Microsoft 365 Group with specific ID
|
|
27
33
|
|
|
28
34
|
```sh
|
|
29
35
|
m365 aad o365group recyclebinitem restore --id 28beab62-7540-4db1-a23f-29a6018a3848
|
|
30
36
|
```
|
|
37
|
+
|
|
38
|
+
Restores the Microsoft 365 Group with specific name
|
|
39
|
+
|
|
40
|
+
```sh
|
|
41
|
+
m365 aad o365group recyclebinitem restore --displayName "My Group"
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Restores the Microsoft 365 Group with specific mail nickname
|
|
45
|
+
|
|
46
|
+
```sh
|
|
47
|
+
m365 aad o365group recyclebinitem restore --mailNickname "Mygroup"
|
|
48
|
+
```
|
|
@@ -20,10 +20,13 @@ m365 spo field set [options]
|
|
|
20
20
|
: Title of the list where the field is located (if list column). Specify `listTitle` or `listId` but not both
|
|
21
21
|
|
|
22
22
|
`-i, --id [id]`
|
|
23
|
-
: ID of the field to update. Specify `
|
|
23
|
+
: ID of the field to update. Specify `id` or `title` but not both
|
|
24
|
+
|
|
25
|
+
`-t, --title [title]`
|
|
26
|
+
: Title or internal name of the field to update. Specify `id` or `title` but not both
|
|
24
27
|
|
|
25
28
|
`-n, --name [name]`
|
|
26
|
-
: Title or internal name of the field to update. Specify `
|
|
29
|
+
: (deprecated. Use `title` instead) Title or internal name of the field to update. Specify `id` or `name` but not both
|
|
27
30
|
|
|
28
31
|
`--updateExistingLists`
|
|
29
32
|
: Set, to push the update to existing lists. Otherwise, the changes will apply to new lists only
|
|
@@ -39,7 +42,7 @@ Specify properties to update using their names, eg. `--Title 'New Title' --JSLin
|
|
|
39
42
|
Update the title of the site column specified by its internal name and push changes to existing lists
|
|
40
43
|
|
|
41
44
|
```sh
|
|
42
|
-
m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --
|
|
45
|
+
m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --title 'MyColumn' --updateExistingLists --Title 'My column'
|
|
43
46
|
```
|
|
44
47
|
|
|
45
48
|
Update the title of the list column specified by its ID
|
|
@@ -51,5 +54,5 @@ m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --lis
|
|
|
51
54
|
Update column formatting of the specified list column
|
|
52
55
|
|
|
53
56
|
```sh
|
|
54
|
-
m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'My List' --
|
|
57
|
+
m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'My List' --title 'MyColumn' --CustomFormatter '`{"schema":"https://developer.microsoft.com/json-schemas/sp/column-formatting.schema.json", "elmType": "div", "txtContent": "@currentField"}`'
|
|
55
58
|
```
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
# spo group add
|
|
2
|
+
|
|
3
|
+
Creates group in the specified site
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
m365 spo group add [options]
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Options
|
|
12
|
+
|
|
13
|
+
`-u, --webUrl <webUrl>`
|
|
14
|
+
: URL of the site where the group should be added.
|
|
15
|
+
|
|
16
|
+
`-n, --name <name>`
|
|
17
|
+
: Name of the group to add.
|
|
18
|
+
|
|
19
|
+
`--description [description]`
|
|
20
|
+
: The description for the group.
|
|
21
|
+
|
|
22
|
+
`--allowMembersEditMembership [allowMembersEditMembership]`
|
|
23
|
+
: Who can edit the membership of the group? When `true` members can edit membership, otherwise only owners can do this. Default `false`.
|
|
24
|
+
|
|
25
|
+
`--onlyAllowMembersViewMembership [onlyAllowMembersViewMembership]`
|
|
26
|
+
: Who can view the membership of the group? When `false` everyone can view the group membership, otherwise only group members can. Default `true`.
|
|
27
|
+
|
|
28
|
+
`--allowRequestToJoinLeave [allowRequestToJoinLeave]`
|
|
29
|
+
: Specify whether to allow users to request membership in this group and allow users to request to leave the group. Default `false`.
|
|
30
|
+
|
|
31
|
+
`--autoAcceptRequestToJoinLeave [autoAcceptRequestToJoinLeave]`
|
|
32
|
+
: If auto-accept is enabled, users will automatically be added or removed when they make a request. Default `false`.
|
|
33
|
+
|
|
34
|
+
`--requestToJoinLeaveEmailSetting [requestToJoinLeaveEmailSetting]`
|
|
35
|
+
: All membership requests will be sent to the email address specified.
|
|
36
|
+
|
|
37
|
+
--8<-- "docs/cmd/_global.md"
|
|
38
|
+
|
|
39
|
+
## Examples
|
|
40
|
+
|
|
41
|
+
Create group with title and description
|
|
42
|
+
|
|
43
|
+
```sh
|
|
44
|
+
m365 spo group add --webUrl https://contoso.sharepoint.com/sites/project-x --name "Project leaders" --description "This group contains all project leaders"
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Create group with membership requests
|
|
48
|
+
|
|
49
|
+
```sh
|
|
50
|
+
m365 spo group add --webUrl https://contoso.sharepoint.com/sites/project-x --name "Project leaders" --allowRequestToJoinLeave true --requestToJoinLeaveEmailSetting john.doe@contoso.com
|
|
51
|
+
```
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# spo group set
|
|
2
|
+
|
|
3
|
+
Updates a group in the specified site
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
m365 spo group set [options]
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Options
|
|
12
|
+
|
|
13
|
+
`-u, --webUrl <webUrl>`
|
|
14
|
+
: URL of the site where the group is located.
|
|
15
|
+
|
|
16
|
+
`-i, --id [id]`
|
|
17
|
+
: ID of the group to update. Specify either `id` or `name` but not both.
|
|
18
|
+
|
|
19
|
+
`-n, --name [name]`
|
|
20
|
+
: Name of the group. Specify either `id` or `name` but not both.
|
|
21
|
+
|
|
22
|
+
`--newName [newName]`
|
|
23
|
+
: New name for the group.
|
|
24
|
+
|
|
25
|
+
`--description [description]`
|
|
26
|
+
: The description for the group.
|
|
27
|
+
|
|
28
|
+
`--allowMembersEditMembership [allowMembersEditMembership]`
|
|
29
|
+
: Who can edit the membership of the group? When `true` members can edit membership, otherwise only owners can do this.
|
|
30
|
+
|
|
31
|
+
`--onlyAllowMembersViewMembership [onlyAllowMembersViewMembership]`
|
|
32
|
+
: Who can view the membership of the group? When `true` only group members can view the membership, otherwise everyone can.
|
|
33
|
+
|
|
34
|
+
`--allowRequestToJoinLeave [allowRequestToJoinLeave]`
|
|
35
|
+
: Specify whether to allow users to request membership in this group and allow users to request to leave the group.
|
|
36
|
+
|
|
37
|
+
`--autoAcceptRequestToJoinLeave [autoAcceptRequestToJoinLeave]`
|
|
38
|
+
: If auto-accept is enabled, users will automatically be added or removed when they make a request.
|
|
39
|
+
|
|
40
|
+
`--requestToJoinLeaveEmailSetting [requestToJoinLeaveEmailSetting]`
|
|
41
|
+
: All membership requests will be sent to the email address specified.
|
|
42
|
+
|
|
43
|
+
`--ownerEmail [ownerEmail]`
|
|
44
|
+
: Set user with this email as owner of the group. Specify either `ownerEmail` or `ownerUserName` but not both.
|
|
45
|
+
|
|
46
|
+
`--ownerUserName [ownerUserName]`
|
|
47
|
+
: Set user with this login name as owner of the group. Specify either `ownerEmail` or `ownerUserName` but not both.
|
|
48
|
+
|
|
49
|
+
--8<-- "docs/cmd/_global.md"
|
|
50
|
+
|
|
51
|
+
## Examples
|
|
52
|
+
|
|
53
|
+
Update group title and description
|
|
54
|
+
|
|
55
|
+
```sh
|
|
56
|
+
m365 spo group set --webUrl https://contoso.sharepoint.com/sites/project-x --id 18 --newTitle "Project leaders" --description "This group contains all project leaders"
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Update group with membership requests
|
|
60
|
+
|
|
61
|
+
```sh
|
|
62
|
+
m365 spo group set --webUrl https://contoso.sharepoint.com/sites/project-x --title "Project leaders" --allowRequestToJoinLeave true --requestToJoinLeaveEmailSetting john.doe@contoso.com
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Sets a specified user as group owner
|
|
66
|
+
|
|
67
|
+
```sh
|
|
68
|
+
m365 spo group set --webUrl https://contoso.sharepoint.com/sites/project-x --id 18 --ownerEmail john.doe@contoso.com
|
|
69
|
+
```
|
|
@@ -19,6 +19,9 @@ m365 spo hubsite get [options]
|
|
|
19
19
|
`-u, --url [url]`
|
|
20
20
|
: URL of the hubsite. Specify either `id`, `title` or `url` but not multiple.
|
|
21
21
|
|
|
22
|
+
`--includeAssociatedSites`
|
|
23
|
+
: Include the associated sites in the result (only in JSON output)
|
|
24
|
+
|
|
22
25
|
--8<-- "docs/cmd/_global.md"
|
|
23
26
|
|
|
24
27
|
## Examples
|
|
@@ -41,6 +44,24 @@ Get information about the hub site with URL _https://contoso.sharepoint.com/site
|
|
|
41
44
|
m365 spo hubsite get --url 'https://contoso.sharepoint.com/sites/HubSite'
|
|
42
45
|
```
|
|
43
46
|
|
|
47
|
+
Get information about the hub site with ID _2c1ba4c4-cd9b-4417-832f-92a34bc34b2a_, including its associated sites. Associated site info is only shown in JSON output.
|
|
48
|
+
|
|
49
|
+
```sh
|
|
50
|
+
m365 spo hubsite get --id 2c1ba4c4-cd9b-4417-832f-92a34bc34b2a --includeAssociatedSites --output json
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
Get information about the hub site with Title _My Hub Site_
|
|
54
|
+
|
|
55
|
+
```sh
|
|
56
|
+
m365 spo hubsite get --title "My Hub Site"
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Get information about the hub site with URL _https://contoso.sharepoint.com/sites/HubSite_
|
|
60
|
+
|
|
61
|
+
```sh
|
|
62
|
+
m365 spo hubsite get --url "https://contoso.sharepoint.com/sites/HubSite"
|
|
63
|
+
```
|
|
64
|
+
|
|
44
65
|
## More information
|
|
45
66
|
|
|
46
67
|
- SharePoint hub sites new in Microsoft 365: [https://techcommunity.microsoft.com/t5/SharePoint-Blog/SharePoint-hub-sites-new-in-Office-365/ba-p/109547](https://techcommunity.microsoft.com/t5/SharePoint-Blog/SharePoint-hub-sites-new-in-Office-365/ba-p/109547)
|
|
@@ -24,6 +24,9 @@ m365 spo site classic list [options]
|
|
|
24
24
|
!!! important
|
|
25
25
|
To use this command you have to have permissions to access the tenant admin site.
|
|
26
26
|
|
|
27
|
+
!!! important
|
|
28
|
+
This command is deprecated. Please use [spo site list](./site-list.md) instead.
|
|
29
|
+
|
|
27
30
|
## Remarks
|
|
28
31
|
|
|
29
32
|
Using the `-t, --webTemplate` option you can specify which sites you want to retrieve. For example, to get sites with the `STS#0` as their web template, use `--webTemplate STS#0` as the option.
|
|
@@ -10,12 +10,18 @@ m365 spo site list [options]
|
|
|
10
10
|
|
|
11
11
|
## Options
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
: type of
|
|
13
|
+
`-t, --type [type]`
|
|
14
|
+
: type of sites to list. Allowed values are `TeamSite,CommunicationSite,All`. The default value is `TeamSite`.
|
|
15
|
+
|
|
16
|
+
`--webTemplate [webTemplate]`
|
|
17
|
+
: types of sites to list. To be used with values like `GROUP#0` and `SITEPAGEPUBLISHING#0`. Specify either `type` or `webTemplate`, but not both.
|
|
15
18
|
|
|
16
19
|
`-f, --filter [filter]`
|
|
17
20
|
: filter to apply when retrieving sites
|
|
18
21
|
|
|
22
|
+
`--includeOneDriveSites`
|
|
23
|
+
: use this switch to include OneDrive sites in the result when retrieving sites. Can only be used in combination with `type` All.
|
|
24
|
+
|
|
19
25
|
`--deleted`
|
|
20
26
|
: use this switch to only return deleted sites
|
|
21
27
|
|
|
@@ -32,30 +38,36 @@ When using the text output type (default), the command lists only the values of
|
|
|
32
38
|
|
|
33
39
|
## Examples
|
|
34
40
|
|
|
35
|
-
List all
|
|
41
|
+
List all sites in the currently connected tenant
|
|
36
42
|
|
|
37
43
|
```sh
|
|
38
|
-
m365 spo site list
|
|
44
|
+
m365 spo site list --type All
|
|
39
45
|
```
|
|
40
46
|
|
|
41
|
-
List all
|
|
47
|
+
List all group connected team sites in the currently connected tenant
|
|
42
48
|
|
|
43
49
|
```sh
|
|
44
50
|
m365 spo site list --type TeamSite
|
|
45
51
|
```
|
|
46
52
|
|
|
47
|
-
List all
|
|
53
|
+
List all communication sites in the currently connected tenant
|
|
48
54
|
|
|
49
55
|
```sh
|
|
50
56
|
m365 spo site list --type CommunicationSite
|
|
51
57
|
```
|
|
52
58
|
|
|
53
|
-
List all
|
|
59
|
+
List all group connected team sites that contain _project_ in the URL
|
|
54
60
|
|
|
55
61
|
```sh
|
|
56
62
|
m365 spo site list --type TeamSite --filter "Url -like 'project'"
|
|
57
63
|
```
|
|
58
64
|
|
|
65
|
+
List all sites in the currently connected tenant including OneDrive sites
|
|
66
|
+
|
|
67
|
+
```sh
|
|
68
|
+
m365 spo site list --type All --includeOneDriveSites
|
|
69
|
+
```
|
|
70
|
+
|
|
59
71
|
List all deleted sites in the tenant you're logged in to
|
|
60
72
|
|
|
61
73
|
```sh
|