@pnp/cli-microsoft365 7.0.0-beta.b7c2a8d → 7.0.0-beta.c0afb7b

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 (131) hide show
  1. package/.eslintrc.cjs +1 -3
  2. package/dist/GlobalOptions.js +1 -7
  3. package/dist/cli/Cli.js +19 -2
  4. package/dist/m365/aad/commands/{o365group/o365group-add.js → m365group/m365group-add.js} +17 -17
  5. package/dist/m365/aad/commands/{o365group/o365group-conversation-list.js → m365group/m365group-conversation-list.js} +10 -10
  6. package/dist/m365/aad/commands/{o365group/o365group-conversation-post-list.js → m365group/m365group-conversation-post-list.js} +14 -14
  7. package/dist/m365/aad/commands/{o365group/o365group-get.js → m365group/m365group-get.js} +13 -10
  8. package/dist/m365/aad/commands/{o365group/o365group-list.js → m365group/m365group-list.js} +13 -28
  9. package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-clear.js → m365group/m365group-recyclebinitem-clear.js} +15 -15
  10. package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-list.js → m365group/m365group-recyclebinitem-list.js} +10 -10
  11. package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-remove.js → m365group/m365group-recyclebinitem-remove.js} +14 -14
  12. package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-restore.js → m365group/m365group-recyclebinitem-restore.js} +14 -14
  13. package/dist/m365/aad/commands/{o365group/o365group-remove.js → m365group/m365group-remove.js} +12 -12
  14. package/dist/m365/aad/commands/{o365group/o365group-renew.js → m365group/m365group-renew.js} +10 -10
  15. package/dist/m365/aad/commands/{o365group/o365group-report-activitycounts.js → m365group/m365group-report-activitycounts.js} +4 -4
  16. package/dist/m365/aad/commands/{o365group/o365group-report-activitydetail.js → m365group/m365group-report-activitydetail.js} +4 -4
  17. package/dist/m365/aad/commands/{o365group/o365group-report-activityfilecounts.js → m365group/m365group-report-activityfilecounts.js} +4 -4
  18. package/dist/m365/aad/commands/{o365group/o365group-report-activitygroupcounts.js → m365group/m365group-report-activitygroupcounts.js} +4 -4
  19. package/dist/m365/aad/commands/{o365group/o365group-report-activitystorage.js → m365group/m365group-report-activitystorage.js} +4 -4
  20. package/dist/m365/aad/commands/{o365group/o365group-set.js → m365group/m365group-set.js} +17 -17
  21. package/dist/m365/aad/commands/{o365group/o365group-teamify.js → m365group/m365group-teamify.js} +14 -14
  22. package/dist/m365/aad/commands/{o365group/o365group-user-add.js → m365group/m365group-user-add.js} +14 -14
  23. package/dist/m365/aad/commands/{o365group/o365group-user-list.js → m365group/m365group-user-list.js} +12 -12
  24. package/dist/m365/aad/commands/{o365group/o365group-user-remove.js → m365group/m365group-user-remove.js} +14 -14
  25. package/dist/m365/aad/commands/{o365group/o365group-user-set.js → m365group/m365group-user-set.js} +15 -15
  26. package/dist/m365/aad/commands.js +22 -22
  27. package/dist/m365/pa/commands/app/app-permission-list.js +2 -2
  28. package/dist/m365/pa/commands/app/app-permission-remove.js +3 -3
  29. package/dist/m365/pa/commands.js +1 -4
  30. package/dist/m365/spfx/commands/project/project-doctor/{doctor-1.18.0-beta.1.js → doctor-1.18.0-beta.5.js} +1 -1
  31. package/dist/m365/spfx/commands/project/project-doctor.js +1 -1
  32. package/dist/m365/spfx/commands/project/project-upgrade/upgrade-1.15.2.js +1 -1
  33. package/dist/m365/spfx/commands/project/project-upgrade/{upgrade-1.18.0-beta.1.js → upgrade-1.18.0-beta.5.js} +26 -26
  34. package/dist/m365/spfx/commands/project/project-upgrade.js +1 -1
  35. package/dist/m365/spfx/commands/spfx-doctor.js +3 -3
  36. package/dist/m365/spo/commands/app/SpoAppBaseCommand.js +27 -26
  37. package/dist/m365/spo/commands/app/app-add.js +9 -9
  38. package/dist/m365/spo/commands/file/file-copy.js +1 -1
  39. package/dist/m365/spo/commands/file/file-move.js +73 -97
  40. package/dist/m365/spo/commands/folder/folder-copy.js +89 -45
  41. package/dist/m365/spo/commands/folder/folder-move.js +89 -47
  42. package/dist/m365/spo/commands/orgassetslibrary/orgassetslibrary-add.js +32 -3
  43. package/dist/m365/spo/commands/page/clientsidepages.js +1 -81
  44. package/dist/m365/spo/commands/propertybag/propertybag-base.js +63 -59
  45. package/dist/m365/spo/commands/propertybag/propertybag-remove.js +28 -31
  46. package/dist/m365/spo/commands/site/FlowsPolicy.js +7 -0
  47. package/dist/m365/spo/commands/site/site-ensure.js +3 -3
  48. package/dist/m365/spo/commands/site/site-hubsite-disconnect.js +22 -22
  49. package/dist/m365/spo/commands/site/site-list.js +27 -43
  50. package/dist/m365/spo/commands/site/site-set.js +60 -49
  51. package/dist/m365/spo/commands/theme/theme-list.js +1 -9
  52. package/dist/m365/spo/commands/theme/theme-remove.js +24 -24
  53. package/dist/m365/spo/commands/theme/theme-set.js +0 -1
  54. package/dist/m365/spo/commands/user/user-remove.js +27 -27
  55. package/dist/m365/spo/commands/web/web-reindex.js +35 -42
  56. package/dist/m365/spo/commands/web/web-remove.js +21 -21
  57. package/dist/m365/spo/commands/web/web-roleassignment-add.js +16 -31
  58. package/dist/m365/spo/commands/web/web-roleassignment-remove.js +33 -44
  59. package/dist/m365/spo/commands/web/web-roleinheritance-break.js +18 -18
  60. package/dist/m365/spo/commands/web/web-roleinheritance-reset.js +19 -19
  61. package/dist/m365/yammer/commands/message/message-like-set.js +27 -28
  62. package/dist/m365/yammer/commands/message/message-list.js +62 -81
  63. package/dist/m365/yammer/commands/message/message-remove.js +18 -18
  64. package/dist/m365/yammer/commands/yammer-search.js +53 -69
  65. package/dist/utils/spo.js +12 -53
  66. package/dist/utils/validation.js +0 -3
  67. package/docs/docs/cmd/aad/{o365group/o365group-add.mdx → m365group/m365group-add.mdx} +13 -13
  68. package/docs/docs/cmd/aad/{o365group/o365group-conversation-list.mdx → m365group/m365group-conversation-list.mdx} +4 -4
  69. package/docs/docs/cmd/aad/{o365group/o365group-conversation-post-list.mdx → m365group/m365group-conversation-post-list.mdx} +8 -8
  70. package/docs/docs/cmd/aad/{o365group/o365group-get.mdx → m365group/m365group-get.mdx} +6 -6
  71. package/docs/docs/cmd/aad/{o365group/o365group-list.mdx → m365group/m365group-list.mdx} +12 -29
  72. package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-clear.mdx → m365group/m365group-recyclebinitem-clear.mdx} +5 -5
  73. package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-list.mdx → m365group/m365group-recyclebinitem-list.mdx} +8 -8
  74. package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-remove.mdx → m365group/m365group-recyclebinitem-remove.mdx} +6 -6
  75. package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-restore.mdx → m365group/m365group-recyclebinitem-restore.mdx} +6 -6
  76. package/docs/docs/cmd/aad/{o365group/o365group-remove.mdx → m365group/m365group-remove.mdx} +6 -6
  77. package/docs/docs/cmd/aad/{o365group/o365group-renew.mdx → m365group/m365group-renew.mdx} +4 -4
  78. package/docs/docs/cmd/aad/{o365group/o365group-report-activitycounts.mdx → m365group/m365group-report-activitycounts.mdx} +6 -6
  79. package/docs/docs/cmd/aad/{o365group/o365group-report-activitydetail.mdx → m365group/m365group-report-activitydetail.mdx} +7 -7
  80. package/docs/docs/cmd/aad/{o365group/o365group-report-activityfilecounts.mdx → m365group/m365group-report-activityfilecounts.mdx} +6 -6
  81. package/docs/docs/cmd/aad/{o365group/o365group-report-activitygroupcounts.mdx → m365group/m365group-report-activitygroupcounts.mdx} +6 -6
  82. package/docs/docs/cmd/aad/{o365group/o365group-report-activitystorage.mdx → m365group/m365group-report-activitystorage.mdx} +6 -6
  83. package/docs/docs/cmd/aad/{o365group/o365group-set.mdx → m365group/m365group-set.mdx} +8 -8
  84. package/docs/docs/cmd/aad/{o365group/o365group-teamify.mdx → m365group/m365group-teamify.mdx} +5 -5
  85. package/docs/docs/cmd/aad/{o365group/o365group-user-add.mdx → m365group/m365group-user-add.mdx} +5 -5
  86. package/docs/docs/cmd/aad/{o365group/o365group-user-list.mdx → m365group/m365group-user-list.mdx} +7 -7
  87. package/docs/docs/cmd/aad/{o365group/o365group-user-remove.mdx → m365group/m365group-user-remove.mdx} +5 -5
  88. package/docs/docs/cmd/aad/{o365group/o365group-user-set.mdx → m365group/m365group-user-set.mdx} +5 -5
  89. package/docs/docs/cmd/pa/app/app-permission-remove.mdx +1 -1
  90. package/docs/docs/cmd/planner/plan/plan-add.mdx +1 -1
  91. package/docs/docs/cmd/spo/file/file-move.mdx +36 -18
  92. package/docs/docs/cmd/spo/folder/folder-copy.mdx +39 -12
  93. package/docs/docs/cmd/spo/folder/folder-move.mdx +40 -13
  94. package/docs/docs/cmd/spo/orgassetslibrary/orgassetslibrary-add.mdx +14 -1
  95. package/docs/docs/cmd/spo/site/site-add.mdx +1 -1
  96. package/docs/docs/cmd/spo/site/site-ensure.mdx +1 -1
  97. package/docs/docs/cmd/spo/site/site-list.mdx +3 -78
  98. package/docs/docs/cmd/teams/team/team-add.mdx +1 -1
  99. package/npm-shrinkwrap.json +178 -1304
  100. package/package.json +5 -7
  101. package/dist/m365/pa/cds-project-mutator.js +0 -91
  102. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/dataset-template/generated/ManifestTypes.d.ts +0 -11
  103. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/dataset-template/template_ControlManifest.Input.xml +0 -31
  104. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/dataset-template/template_index.ts +0 -51
  105. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/field-template/generated/ManifestTypes.d.ts +0 -12
  106. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/field-template/template_ControlManifest.Input.xml +0 -37
  107. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/field-template/template_index.ts +0 -48
  108. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/index.ts +0 -0
  109. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-dataset-template/template_ControlManifest.Input.xml +0 -31
  110. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-dataset-template/template_index.tsx +0 -58
  111. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-field-template/template_ControlManifest.Input.xml +0 -37
  112. package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-field-template/template_index.tsx +0 -55
  113. package/dist/m365/pa/commands/pcf/pcf-init/assets/package.json +0 -19
  114. package/dist/m365/pa/commands/pcf/pcf-init/assets/pcfconfig.json +0 -3
  115. package/dist/m365/pa/commands/pcf/pcf-init/assets/template_.gitignore +0 -14
  116. package/dist/m365/pa/commands/pcf/pcf-init/assets/template_pcfprojecttype.pcfproj +0 -45
  117. package/dist/m365/pa/commands/pcf/pcf-init/pcf-init-variables.js +0 -2
  118. package/dist/m365/pa/commands/pcf/pcf-init.js +0 -120
  119. package/dist/m365/pa/commands/solution/solution-init/assets/Other/Customizations.xml +0 -18
  120. package/dist/m365/pa/commands/solution/solution-init/assets/Other/Relationships.xml +0 -2
  121. package/dist/m365/pa/commands/solution/solution-init/assets/Other/template_Solution.xml +0 -94
  122. package/dist/m365/pa/commands/solution/solution-init/assets/template_.gitignore +0 -2
  123. package/dist/m365/pa/commands/solution/solution-init/assets/template_solutionprojecttype.cdsproj +0 -44
  124. package/dist/m365/pa/commands/solution/solution-init/solution-init-variables.js +0 -2
  125. package/dist/m365/pa/commands/solution/solution-init.js +0 -126
  126. package/dist/m365/pa/commands/solution/solution-reference-add.js +0 -88
  127. package/dist/m365/pa/template-instantiator.js +0 -57
  128. package/docs/docs/cmd/pa/pcf/pcf-init.mdx +0 -56
  129. package/docs/docs/cmd/pa/solution/solution-init.mdx +0 -46
  130. package/docs/docs/cmd/pa/solution/solution-reference-add.mdx +0 -42
  131. /package/dist/m365/aad/commands/{o365group → m365group}/GroupExtended.js +0 -0
@@ -1,13 +1,13 @@
1
1
  import Global from '/docs/cmd/_global.mdx';
2
2
 
3
- # aad o365group user remove
3
+ # aad m365group user remove
4
4
 
5
5
  Removes the specified user from specified Microsoft 365 Group or Microsoft Teams team
6
6
 
7
7
  ## Usage
8
8
 
9
9
  ```sh
10
- m365 aad o365group user remove [options]
10
+ m365 aad m365group user remove [options]
11
11
  ```
12
12
 
13
13
  ## Alias
@@ -43,13 +43,13 @@ You can remove users from a Microsoft 365 Group or Microsoft Teams team if you a
43
43
  Removes user from the specified Microsoft 365 Group
44
44
 
45
45
  ```sh
46
- m365 aad o365group user remove --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com'
46
+ m365 aad m365group user remove --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com'
47
47
  ```
48
48
 
49
49
  Removes user from the specified Microsoft 365 Group without confirmation
50
50
 
51
51
  ```sh
52
- m365 aad o365group user remove --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com' --force
52
+ m365 aad m365group user remove --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com' --force
53
53
  ```
54
54
 
55
55
  Removes user from the specified Microsoft Teams team
@@ -60,4 +60,4 @@ m365 aad teams user remove --teamId '00000000-0000-0000-0000-000000000000' --use
60
60
 
61
61
  ## Response
62
62
 
63
- The command won't return a response on success.
63
+ The command won't return a response on success.
@@ -1,13 +1,13 @@
1
1
  import Global from '/docs/cmd/_global.mdx';
2
2
 
3
- # aad o365group user set
3
+ # aad m365group user set
4
4
 
5
5
  Updates role of the specified user in the specified Microsoft 365 Group or Microsoft Teams team
6
6
 
7
7
  ## Usage
8
8
 
9
9
  ```sh
10
- m365 aad o365group user set [options]
10
+ m365 aad m365group user set [options]
11
11
  ```
12
12
 
13
13
  ## Alias
@@ -43,13 +43,13 @@ The command will return an error if the user already has the specified role in t
43
43
  Promote the specified user to owner of the given Microsoft 365 Group
44
44
 
45
45
  ```sh
46
- m365 aad o365group user set --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com' --role Owner
46
+ m365 aad m365group user set --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com' --role Owner
47
47
  ```
48
48
 
49
49
  Demote the specified user from owner to member in the given Microsoft 365 Group
50
50
 
51
51
  ```sh
52
- m365 aad o365group user set --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com' --role Member
52
+ m365 aad m365group user set --groupId '00000000-0000-0000-0000-000000000000' --userName 'anne.matthews@contoso.onmicrosoft.com' --role Member
53
53
  ```
54
54
 
55
55
  Promote the specified user to owner of the given Microsoft Teams team
@@ -66,4 +66,4 @@ m365 aad teams user set --teamId '00000000-0000-0000-0000-000000000000' --userNa
66
66
 
67
67
  ## Response
68
68
 
69
- The command won't return a response on success.
69
+ The command won't return a response on success.
@@ -37,7 +37,7 @@ m365 pa app permission remove [options]
37
37
  `-e, --environmentName [environmentName]`
38
38
  : The name of the environment. Specify only a value when running the command as admin.
39
39
 
40
- `--confirm`
40
+ `-f, --force`
41
41
  : Don't prompt for confirmation.
42
42
  ```
43
43
 
@@ -38,7 +38,7 @@ m365 planner plan add [options]
38
38
 
39
39
  ## Remarks
40
40
 
41
- - Related to the options `--shareWithUserIds` and `--shareWithUserNames`. If you are leveraging Microsoft 365 groups, use the `aad o365group user` commands to manage group membership to share the [group's](https://pnp.github.io/cli-microsoft365/cmd/aad/o365group/o365group-user-add/) plan. You can also add existing members of the group to this collection though it is not required for them to access the plan owned by the group.
41
+ - Related to the options `--shareWithUserIds` and `--shareWithUserNames`. If you are leveraging Microsoft 365 groups, use the `aad m365group user` commands to manage group membership to share the [group's](https://pnp.github.io/cli-microsoft365/cmd/aad/m365group/m365group-user-add/) plan. You can also add existing members of the group to this collection though it is not required for them to access the plan owned by the group.
42
42
 
43
43
  - Hint: Unlike for groups, a Planner Roster can contain only 1 plan.
44
44
 
@@ -14,53 +14,71 @@ m365 spo file move [options]
14
14
 
15
15
  ```md definition-list
16
16
  `-u, --webUrl <webUrl>`
17
- : The URL of the site where the file is located
17
+ : The URL of the site where the file is located.
18
18
 
19
- `-s, --sourceUrl <sourceUrl>`
20
- : The server- or site-relative decoded URL of the file to move
19
+ `-s, --sourceUrl [sourceUrl]`
20
+ : The server-, site-relative or absolute decoded URL of the file to move. Specify either `sourceUrl` or `sourceId` but not both.
21
+
22
+ `-i, --sourceId [sourceId]`
23
+ : The ID of the file to move. Specify either `sourceUrl` or `sourceId` but not both.
21
24
 
22
25
  `-t, --targetUrl <targetUrl>`
23
- : Server-relative decoded URL where to move the file
26
+ : Server-relative or absolute decoded URL where to move the file.
27
+
28
+ `--newName [newName]`
29
+ : The new name of the destination file.
24
30
 
25
- `--deleteIfAlreadyExists`
26
- : If a file already exists at the targetUrl, it will be moved to the recycle bin. If omitted, the move operation will be canceled if the file already exists at the targetUrl location
31
+ `--nameConflictBehavior [nameConflictBehavior]`
32
+ : Behavior when a file or folder with the same name is already present at the destination. Possible values: `fail`, `replace`, `rename`. The default is `fail`.
27
33
 
28
- `--allowSchemaMismatch`
29
- : Ignores any missing fields in the target document library and moves the file anyway
34
+ `--retainEditorAndModified`
35
+ : Use this option to retain the editor and modified date. When not specified, these values are reset when moving to another library.
36
+
37
+ `--bypassSharedLock`
38
+ : This indicates whether a file with a share lock can still be moved. Use this option to move a file that is locked.
30
39
  ```
31
40
 
32
41
  <Global />
33
42
 
34
43
  ## Remarks
35
44
 
36
- When you move a file using the `spo file move` command, all of the versions are being moved.
45
+ All file versions are retained while moving a file.
46
+
47
+ When you specify a value for `nameConflictBehavior`, consider the following:
48
+
49
+ - `fail` will throw an error when the destination file already exists.
50
+ - `replace` will replace the destination file if it already exists.
51
+ - `rename` will add a suffix (e.g. Document1.pdf) when the destination file already exists.
37
52
 
38
53
  ## Examples
39
54
 
40
- Move file to a document library in another site collection
55
+ Move a file to a document library in another site collection by server relative URL
41
56
 
42
57
  ```sh
43
- m365 spo file move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /sites/test1/Shared%20Documents/sp1.pdf --targetUrl /sites/test2/Shared%20Documents/
58
+ m365 spo file move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/sites/project-x/Shared Documents/sp1.pdf" --targetUrl "/sites/project-y/Archived documents"
44
59
  ```
45
60
 
46
- Move file to a document library in the same site collection
61
+ Move a file specified by a server-relative URL to a document library and rename it
47
62
 
48
63
  ```sh
49
- m365 spo file move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/sp1.pdf --targetUrl /sites/test1/HRDocuments/
64
+ m365 spo file move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/Shared Documents/sp1.pdf" --targetUrl "/sites/project-x/My Documents" --newName Report.pdf
50
65
  ```
51
66
 
52
- Move file to a document library in another site collection. If a file with the same name already exists in the target document library, move it to the recycle bin
67
+ Move a file to another document library and replace a file with the same name
53
68
 
54
69
  ```sh
55
- m365 spo file move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/sp1.pdf --targetUrl /sites/test2/Shared%20Documents/ --deleteIfAlreadyExists
70
+ m365 spo file move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/Shared Documents/Report project-x.pdf" --targetUrl "/sites/project-x/My Documents" --newName Report.pdf --nameConflictBehavior replace
56
71
  ```
57
72
 
58
- Move file to a document library in another site collection. Allow for schema mismatch
73
+ Move a file referenced by its ID to another document library and retain editor and modified date
59
74
 
60
- ```sh
61
- m365 spo file move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /sites/test1/Shared%20Documents/sp1.pdf --targetUrl /sites/test2/Shared%20Documents/ --allowSchemaMismatch
75
+ ```sh
76
+ m365 spo file move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceId b8cc341b-9c11-4f2d-aa2b-0ce9c18bcba2 --targetUrl "/sites/project-x/My Documents" --retainEditorAndModified
62
77
  ```
63
78
 
79
+ ## Response
80
+
81
+ The command won't return a response on success.
64
82
 
65
83
  ## More information
66
84
 
@@ -14,16 +14,28 @@ m365 spo folder copy [options]
14
14
 
15
15
  ```md definition-list
16
16
  `-u, --webUrl <webUrl>`
17
- : The URL of the site where the folder is located
17
+ : The URL of the site where the folder is located.
18
18
 
19
- `-s, --sourceUrl <sourceUrl>`
20
- : The server- or site-relative URL of the folder to copy
19
+ `-s, --sourceUrl [sourceUrl]`
20
+ : The server-, site-relative or absolute decoded URL of the folder to copy. Specify either `sourceUrl` or `sourceId` but not both.
21
+
22
+ `-i, --sourceId [sourceId]`
23
+ : The UniqueId (GUID) of the folder. Specify either `sourceUrl` or `sourceId` but not both.
21
24
 
22
25
  `-t, --targetUrl <targetUrl>`
23
- : Server-relative URL where to copy the folder
26
+ : Server-relative or absolute decoded URL where to copy the folder.
27
+
28
+ `--newName [newName]`
29
+ : New name of the destination folder.
30
+
31
+ `--nameConflictBehavior [nameConflictBehavior]`
32
+ : Behavior when a file or folder with the same name is already present at the destination. Possible values: `fail`, `rename`. The default is `fail`.
24
33
 
25
- `--allowSchemaMismatch`
26
- : Ignores any missing fields in the target document library and copies the folder anyway
34
+ `--resetAuthorAndCreated`
35
+ : Use this option to clear the author and created date. When not specified, the values from the source folder are used.
36
+
37
+ `--bypassSharedLock`
38
+ : This indicates whether a folder with a shared lock can still be moved. Use this option to copy a folder that is locked.
27
39
  ```
28
40
 
29
41
  <Global />
@@ -32,26 +44,41 @@ m365 spo folder copy [options]
32
44
 
33
45
  When you copy a folder with documents that have version history, only the latest document version is copied.
34
46
 
47
+ When you specify a value for `nameConflictBehavior`, consider the following:
48
+
49
+ - `fail` will throw an error when the destination folder already exists.
50
+ - `rename` will add a suffix (e.g. Folder1) when the destination folder already exists.
51
+
35
52
  ## Examples
36
53
 
37
- Copies folder from a document library located in one site collection to another site collection
54
+ Copy a folder a folder to another location using server-relative URLs
38
55
 
39
56
  ```sh
40
- m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/MyFolder --targetUrl /sites/test2/Shared%20Documents/
57
+ m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/sites/project-x/Shared Documents/Reports" --targetUrl "/sites/project-y/Shared Documents/Project files"
41
58
  ```
42
59
 
43
- Copies folder from a document library to another site in the same site collection
60
+ Copy a folder a folder to another location using site-relative URLs and rename it
44
61
 
45
62
  ```sh
46
- m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/MyFolder --targetUrl /sites/test1/HRDocuments/
63
+ m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/Shared Documents/Reports" --targetUrl "/sites/project-y/Shared Documents" --newName "Reports January"
47
64
  ```
48
65
 
49
- Copies folder to a document library in another site collection. Allow for schema mismatch
66
+ Copy a folder to another location and use new name on conflict
50
67
 
51
68
  ```sh
52
- m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/MyFolder --targetUrl /sites/test2/Shared%20Documents/ --allowSchemaMismatch
69
+ m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/sites/project-x/Shared Documents/Reports" --targetUrl "/sites/project-y/Shared Documents/Project files" --nameConflictBehavior rename
53
70
  ```
54
71
 
72
+ Copy a folder referenced by its ID to another document library and reset author and created date
73
+
74
+ ```sh
75
+ m365 spo folder copy --webUrl https://contoso.sharepoint.com/sites/project-x --sourceId b8cc341b-9c11-4f2d-aa2b-0ce9c18bcba2 --targetUrl "/sites/project-x/Project files" --retainEditorAndModified
76
+ ```
77
+
78
+ ## Response
79
+
80
+ The command won't return a response on success.
81
+
55
82
  ## More information
56
83
 
57
84
  - Copy items from a SharePoint document library: [https://support.office.com/en-us/article/move-or-copy-items-from-a-sharepoint-document-library-00e2f483-4df3-46be-a861-1f5f0c1a87bc](https://support.office.com/en-us/article/move-or-copy-items-from-a-sharepoint-document-library-00e2f483-4df3-46be-a861-1f5f0c1a87bc)
@@ -14,44 +14,71 @@ m365 spo folder move [options]
14
14
 
15
15
  ```md definition-list
16
16
  `-u, --webUrl <webUrl>`
17
- : The URL of the site where the folder is located
17
+ : The URL of the site where the folder is located.
18
18
 
19
- `-s, --sourceUrl <sourceUrl>`
20
- : The server- or site-relative URL of the folder to move
19
+ `-s, --sourceUrl [sourceUrl]`
20
+ : The server-, site-relative or absolute decoded URL of the folder to move. Specify either `sourceUrl` or `sourceId` but not both.
21
+
22
+ `-i, --sourceId [sourceId]`
23
+ : The ID of the folder to move. Specify either `sourceUrl` or `sourceId` but not both.
21
24
 
22
25
  `-t, --targetUrl <targetUrl>`
23
- : Server-relative URL where to move the folder
26
+ : Server-relative or absolute decoded URL where to move the folder.
27
+
28
+ `--newName [newName]`
29
+ : The new name of the destination folder.
30
+
31
+ `--nameConflictBehavior [nameConflictBehavior]`
32
+ : Behavior when a file or folder with the same name is already present at the destination. Possible values: `fail`, `rename`. The default is `fail`.
24
33
 
25
- `--allowSchemaMismatch`
26
- : Ignores any missing fields in the target destination and moves the folder anyway
34
+ `--retainEditorAndModified`
35
+ : Use this option to retain the editor and modified date. When not specified, these values are reset.
36
+
37
+ `--bypassSharedLock`
38
+ : This indicates whether a folder with a share lock can still be moved. Use this option to move a folder that is locked.
27
39
  ```
28
40
 
29
41
  <Global />
30
42
 
31
43
  ## Remarks
32
44
 
33
- When you move a folder using the `spo folder move` command, all of the document versions are moved.
45
+ All folder versions are retained while moving a folder.
46
+
47
+ When you specify a value for `nameConflictBehavior`, consider the following:
48
+
49
+ - `fail` will throw an error when the destination folder already exists.
50
+ - `rename` will add a suffix (e.g. folder1) when the destination folder already exists.
34
51
 
35
52
  ## Examples
36
53
 
37
- Move folder to a document library in another site collection
54
+ Move a folder to a document library in another site collection by server-relative URL
38
55
 
39
56
  ```sh
40
- m365 spo folder move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/MyFolder --targetUrl /sites/test2/Shared%20Documents/
57
+ m365 spo folder move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/sites/project-x/Shared Documents/Reports" --targetUrl "/sites/project-y/Shared Documents/Reports January"
41
58
  ```
42
59
 
43
- Move folder to a document library in the same site collection
60
+ Move a folder to another location using site-relative URLs and rename it
44
61
 
45
62
  ```sh
46
- m365 spo folder move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/MyFolder --targetUrl /sites/test1/HRDocuments/
63
+ m365 spo folder move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/Shared Documents/Reports" --targetUrl "/sites/project-y/Shared Documents" --newName "Reports January"
47
64
  ```
48
65
 
49
- Move folder to a document library in another site collection. Allow for schema mismatch
66
+ Move a folder to another location and use a new name on conflict
50
67
 
51
68
  ```sh
52
- m365 spo file move --webUrl https://contoso.sharepoint.com/sites/test1 --sourceUrl /Shared%20Documents/sp1.pdf --targetUrl /sites/test2/Shared%20Documents/ --allowSchemaMismatch
69
+ m365 spo folder move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceUrl "/sites/project-x/Shared Documents/Reports" --targetUrl "/sites/project-y/Shared Documents/Project files" --nameConflictBehavior rename
53
70
  ```
54
71
 
72
+ Move a folder referenced by its ID to another document library and retain editor and modified date
73
+
74
+ ```sh
75
+ m365 spo folder move --webUrl https://contoso.sharepoint.com/sites/project-x --sourceId b8cc341b-9c11-4f2d-aa2b-0ce9c18bcba2 --targetUrl "/sites/project-x/Project files" --retainEditorAndModified
76
+ ```
77
+
78
+ ## Response
79
+
80
+ The command won't return a response on success.
81
+
55
82
  ## More information
56
83
 
57
84
  - Move items from a SharePoint document library: [https://support.office.com/en-us/article/move-or-copy-items-from-a-sharepoint-document-library-00e2f483-4df3-46be-a861-1f5f0c1a87bc](https://support.office.com/en-us/article/move-or-copy-items-from-a-sharepoint-document-library-00e2f483-4df3-46be-a861-1f5f0c1a87bc)
@@ -16,11 +16,14 @@ m365 spo orgassetslibrary add [options]
16
16
  `--libraryUrl <libraryUrl>`
17
17
  : The URL of the library to promote.
18
18
 
19
- `--thumbnailUrl <thumbnailUrl>`
19
+ `--thumbnailUrl [thumbnailUrl]`
20
20
  : The URL of the thumbnail to render.
21
21
 
22
22
  `--cdnType [cdnType]`
23
23
  : Specifies the CDN type. Allowed values `Public`, `Private`. Default `Private`.
24
+
25
+ `--orgAssetType [orgAssetType]`
26
+ : Specifies the type of organizational library. Allowed values `ImageDocumentLibrary`, `OfficeTemplateLibrary`, `OfficeFontLibrary`. Defaults to `ImageDocumentLibrary`.
24
27
  ```
25
28
 
26
29
  <Global />
@@ -33,6 +36,10 @@ To use this command you have to have permissions to access the tenant admin site
33
36
 
34
37
  :::
35
38
 
39
+ To enable CDN in your tenant use the [spo cdn set](../cdn/cdn-set.mdx) command.
40
+
41
+ The document library on which you run the command must at least have read permissions for all users, except external users.
42
+
36
43
  ## Examples
37
44
 
38
45
  Promotes an existing library to become an organization assets library
@@ -47,6 +54,12 @@ Promotes an existing library to become an organization assets library with Thumb
47
54
  m365 spo orgassetslibrary --libraryUrl "https://contoso.sharepoint.com/SiteAssets" --thumbnailUrl "https://contoso.sharepoint.com/assets/logo.png"
48
55
  ```
49
56
 
57
+ Promotes an existing library to become an organization assets Office template library
58
+
59
+ ```sh
60
+ m365 spo orgassetslibrary add --libraryUrl "https://contoso.sharepoint.com/SiteAssets" --orgAssetType "OfficeTemplateLibrary"
61
+ ```
62
+
50
63
  ## Response
51
64
 
52
65
  The command won't return a response on success.
@@ -98,7 +98,7 @@ Deleting and creating classic site collections is by default asynchronous and de
98
98
 
99
99
  The `--owners` option is mandatory for creating `CommunicationSite` sites with app-only permissions.
100
100
 
101
- When trying to create a team site using app-only permissions, you will get an _Insufficient privileges to complete the operation._ error. As a workaround, you can use the [`aad o365group add`](../../aad/o365group/o365group-add.mdx) command, followed by [`spo site set`](./site-set.mdx) to further configure the Team site.
101
+ When trying to create a team site using app-only permissions, you will get an _Insufficient privileges to complete the operation._ error. As a workaround, you can use the [`aad m365group add`](../../aad/m365group/m365group-add.mdx) command, followed by [`spo site set`](./site-set.mdx) to further configure the Team site.
102
102
 
103
103
  ## Examples
104
104
 
@@ -103,7 +103,7 @@ If you set the type to `ClassicSite`, you should also set a value of the `webTem
103
103
  Ensure that a site exists at the specified URL. Create a modern team site if no site exists. If a site is found, don't check its type and update its title.
104
104
 
105
105
  ```sh
106
- m365 spo site ensure --url https://contoso.sharepoint.com/sites/team1 --alias team1 --title "Team 1"
106
+ m365 spo site ensure --url https://contoso.sharepoint.com/teams/team1 --alias team1 --title "Team 1"
107
107
  ```
108
108
 
109
109
  Ensure that a communication site exists at the specified URL. Create a communication site if no site exists. If a site of different type is found, return an error.
@@ -26,9 +26,6 @@ m365 spo site list [options]
26
26
 
27
27
  `--includeOneDriveSites`
28
28
  : use this switch to include OneDrive sites in the result when retrieving sites. Do not specify the `type` or `webTemplate` options when using this.
29
-
30
- `--deleted`
31
- : use this switch to only return deleted sites
32
29
  ```
33
30
 
34
31
  <Global />
@@ -39,12 +36,14 @@ Using the `--filter` option you can specify which sites you want to retrieve. Fo
39
36
 
40
37
  When using the text output type, the command lists only the values of the `Title`, and `Url` properties of the site. When setting the output type to JSON, all available properties are included in the command output.
41
38
 
39
+ If you wish to list deleted sites in your tenant, you should use the command [spo tenant recyclebinitem list](../tenant/tenant-recyclebinitem-list.mdx)
40
+
42
41
  :::info
43
42
 
44
43
  To use this command you have to have permissions to access the tenant admin site.
45
44
 
46
45
  :::
47
-
46
+
48
47
  ## Examples
49
48
 
50
49
  List all sites in the currently connected tenant
@@ -77,16 +76,8 @@ List all sites in the currently connected tenant including OneDrive sites
77
76
  m365 spo site list --includeOneDriveSites
78
77
  ```
79
78
 
80
- List all deleted sites in the tenant you're logged in to
81
-
82
- ```sh
83
- m365 spo site list --deleted
84
- ```
85
-
86
79
  ## Response
87
80
 
88
- ### Standard response
89
-
90
81
  <Tabs>
91
82
  <TabItem value="JSON">
92
83
 
@@ -317,69 +308,3 @@ m365 spo site list --deleted
317
308
 
318
309
  </TabItem>
319
310
  </Tabs>
320
-
321
- ### `deleted` response
322
-
323
- When we make use of the `--deleted` option, the response will differ.
324
-
325
- <Tabs>
326
- <TabItem value="JSON">
327
-
328
- ```json
329
- [
330
- {
331
- "_ObjectType_": "Microsoft.Online.SharePoint.TenantAdministration.DeletedSiteProperties",
332
- "_ObjectIdentity_": "b805bfa0-805c-6000-b76d-bc01ecf6c67f|908bed80-a04a-4433-b4a0-883d9847d110:1e852b49-bf4b-4ba5-bcd4-a8c4706c8ed4\\\nDeletedSiteProperties\\\nhttps%3a%2f%2fcontoso.sharepoint.com%2fteams%2fteam1",
333
- "DaysRemaining": 22,
334
- "DeletionTime": "/Date(2023,3,12,8,9,55,260)/",
335
- "SiteId": "/Guid(0031a568-a081-4157-a3ab-0946a9da7f6e)/",
336
- "Status": "Recycled",
337
- "StorageMaximumLevel": 1048576,
338
- "Url": "https://contoso.sharepoint.com/teams/team1",
339
- "UserCodeMaximumLevel": 300
340
- }
341
- ]
342
- ```
343
-
344
- </TabItem>
345
- <TabItem value="Text">
346
-
347
- ```text
348
- Url
349
- -------------------------------------------------
350
- https://contoso.sharepoint.com/teams/team1
351
- ```
352
-
353
- </TabItem>
354
- <TabItem value="CSV">
355
-
356
- ```csv
357
- ObjectType,ObjectIdentity,DaysRemaining,DeletionTime,SiteId,Status,StorageMaximumLevel,Url,UserCodeMaximumLevel
358
- Microsoft.Online.SharePoint.TenantAdministration.DeletedSiteProperties,"fc05bfa0-80db-6000-a541-3d6844d4e148|908bed80-a04a-4433-b4a0-883d9847d110:1e852b49-bf4b-4ba5-bcd4-a8c4706c8ed4,DeletedSiteProperties,https%3a%2f%2fcontoso.sharepoint.com%2fteams%2fteam1",22,/Date(2023,3,12,8,9,55,260)/,/Guid(0031a568-a081-4157-a3ab-0946a9da7f6e)/,Recycled,1048576,https://contoso.sharepoint.com/teams/team1,300
359
- ```
360
-
361
- </TabItem>
362
- <TabItem value="Markdown">
363
-
364
- ```md
365
- # spo site list --deleted "true"
366
-
367
- Date: 2023-06-21
368
-
369
- ## https://contoso.sharepoint.com/teams/team1
370
-
371
- Property | Value
372
- ---------|-------
373
- \_ObjectType\_ | Microsoft.Online.SharePoint.TenantAdministration.DeletedSiteProperties
374
- \_ObjectIdentity\_ | 3b06bfa0-40fd-6000-c2a5-1ef401300d74\|908bed80-a04a-4433-b4a0-883d9847d110:1e852b49-bf4b-4ba5-bcd4-a8c4706c8ed4<br>DeletedSiteProperties<br>https%3a%2f%2fcontoso.sharepoint.com%2fteams%2fteam1
375
- DaysRemaining | 22
376
- DeletionTime | /Date(2023,3,12,8,9,55,260)/
377
- SiteId | /Guid(0031a568-a081-4157-a3ab-0946a9da7f6e)/
378
- Status | Recycled
379
- StorageMaximumLevel | 1048576
380
- Url | https://contoso.sharepoint.com/teams/team1
381
- UserCodeMaximumLevel | 300
382
- ```
383
-
384
- </TabItem>
385
- </Tabs>
@@ -32,7 +32,7 @@ m365 teams team add [options]
32
32
 
33
33
  ## Remarks
34
34
 
35
- If you want to add a Team to an existing Microsoft 365 Group use the [aad o365group teamify](../../aad/o365group/o365group-teamify.mdx) command instead.
35
+ If you want to add a Team to an existing Microsoft 365 Group use the [aad m365group teamify](../../aad/m365group/m365group-teamify.mdx) command instead.
36
36
 
37
37
  This command will return different responses based on the presence of the `--wait` option. If present, the command will return a `group` resource in the response. If not present, the command will return a `teamsAsyncOperation` resource in the response.
38
38