@pnp/cli-microsoft365 6.0.0-beta.42305df → 6.0.0-beta.48a730d

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 (203) hide show
  1. package/.eslintrc.js +15 -2
  2. package/README.md +5 -0
  3. package/dist/Command.js +16 -2
  4. package/dist/m365/aad/commands/app/app-add.js +36 -13
  5. package/dist/m365/aad/commands/app/app-list.js +38 -0
  6. package/dist/m365/aad/commands/user/user-guest-add.js +103 -0
  7. package/dist/m365/aad/commands.js +2 -0
  8. package/dist/m365/commands/status.js +6 -1
  9. package/dist/m365/outlook/commands/mail/mail-send.js +55 -31
  10. package/dist/m365/outlook/commands/message/message-get.js +97 -0
  11. package/dist/m365/outlook/commands.js +1 -0
  12. package/dist/m365/planner/commands/bucket/bucket-get.js +1 -1
  13. package/dist/m365/planner/commands/plan/plan-get.js +5 -20
  14. package/dist/m365/pp/commands/Environment.js +3 -0
  15. package/dist/m365/pp/commands/card/card-get.js +110 -0
  16. package/dist/m365/pp/commands/card/card-list.js +68 -0
  17. package/dist/m365/pp/commands/card/card-remove.js +130 -0
  18. package/dist/m365/pp/commands/dataverse/dataverse-table-list.js +6 -12
  19. package/dist/m365/pp/commands/environment/environment-get.js +75 -0
  20. package/dist/m365/pp/commands/gateway/gateway-get.js +70 -0
  21. package/dist/m365/pp/commands/solution/Solution.js +3 -0
  22. package/dist/m365/pp/commands/solution/solution-get.js +117 -0
  23. package/dist/m365/pp/commands/solution/solution-list.js +87 -0
  24. package/dist/m365/pp/commands.js +7 -0
  25. package/dist/m365/spfx/commands/project/project-doctor.js +4 -1
  26. package/dist/m365/spfx/commands/project/project-externalize.js +4 -1
  27. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010001_YORC_version.js +2 -1
  28. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010002_YORC_isCreatingSolution.js +2 -1
  29. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010003_YORC_packageManager.js +2 -1
  30. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010004_YORC_componentType.js +2 -1
  31. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010005_YORC_environment.js +2 -1
  32. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010006_YORC_framework.js +3 -2
  33. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010007_YORC_isDomainIsolated.js +2 -1
  34. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010008_YORC_nodeVersion.js +2 -1
  35. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010009_YORC_sdkVersions_microsoft_graph_client.js +56 -0
  36. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010010_YORC_sdkVersions_teams_js.js +56 -0
  37. package/dist/m365/spfx/commands/project/project-upgrade/upgrade-1.14.0.js +0 -2
  38. package/dist/m365/spfx/commands/project/project-upgrade/{upgrade-1.16.0-beta.1.js → upgrade-1.16.0-beta.2.js} +44 -28
  39. package/dist/m365/spfx/commands/project/project-upgrade.js +5 -2
  40. package/dist/m365/spfx/commands/spfx-doctor.js +39 -9
  41. package/dist/m365/spo/commands/contenttype/contenttype-add.js +82 -43
  42. package/dist/m365/spo/commands/contenttype/contenttype-field-remove.js +53 -21
  43. package/dist/m365/spo/commands/contenttype/contenttype-get.js +35 -14
  44. package/dist/m365/spo/commands/eventreceiver/EventReceiver.js +3 -0
  45. package/dist/m365/spo/commands/eventreceiver/eventreceiver-remove.js +182 -0
  46. package/dist/m365/spo/commands/field/field-add.js +26 -1
  47. package/dist/m365/spo/commands/field/field-set.js +23 -13
  48. package/dist/m365/spo/commands/file/file-copy.js +25 -39
  49. package/dist/m365/spo/commands/file/file-move.js +24 -37
  50. package/dist/m365/spo/commands/file/file-rename.js +19 -16
  51. package/dist/m365/spo/commands/file/file-roleinheritance-break.js +129 -0
  52. package/dist/m365/spo/commands/folder/folder-list.js +35 -12
  53. package/dist/m365/spo/commands/folder/folder-roleassignment-remove.js +168 -0
  54. package/dist/m365/spo/commands/folder/folder-roleinheritance-break.js +11 -1
  55. package/dist/m365/spo/commands/folder/folder-roleinheritance-reset.js +12 -1
  56. package/dist/m365/spo/commands/group/AssociatedGroupPropertiesCollection.js +3 -0
  57. package/dist/m365/spo/commands/group/group-list.js +49 -10
  58. package/dist/m365/spo/commands/list/list-contenttype-add.js +21 -18
  59. package/dist/m365/spo/commands/list/list-contenttype-default-set.js +59 -47
  60. package/dist/m365/spo/commands/list/list-contenttype-list.js +16 -8
  61. package/dist/m365/spo/commands/list/list-contenttype-remove.js +16 -8
  62. package/dist/m365/spo/commands/list/list-roleassignment-add.js +10 -10
  63. package/dist/m365/spo/commands/list/list-roleassignment-remove.js +8 -8
  64. package/dist/m365/spo/commands/list/list-roleinheritance-break.js +14 -6
  65. package/dist/m365/spo/commands/list/list-roleinheritance-reset.js +14 -6
  66. package/dist/m365/spo/commands/list/list-webhook-add.js +19 -11
  67. package/dist/m365/spo/commands/list/list-webhook-get.js +17 -10
  68. package/dist/m365/spo/commands/list/list-webhook-list.js +17 -42
  69. package/dist/m365/spo/commands/list/list-webhook-remove.js +19 -11
  70. package/dist/m365/spo/commands/list/list-webhook-set.js +27 -20
  71. package/dist/m365/spo/commands/listitem/listitem-add.js +24 -14
  72. package/dist/m365/spo/commands/listitem/listitem-attachment-list.js +18 -8
  73. package/dist/m365/spo/commands/listitem/listitem-get.js +18 -8
  74. package/dist/m365/spo/commands/listitem/listitem-isrecord.js +20 -10
  75. package/dist/m365/spo/commands/listitem/listitem-list.js +21 -11
  76. package/dist/m365/spo/commands/listitem/listitem-record-declare.js +19 -12
  77. package/dist/m365/spo/commands/listitem/listitem-record-undeclare.js +24 -21
  78. package/dist/m365/spo/commands/listitem/listitem-remove.js +19 -11
  79. package/dist/m365/spo/commands/listitem/listitem-roleassignment-add.js +239 -0
  80. package/dist/m365/spo/commands/listitem/listitem-roleassignment-remove.js +8 -8
  81. package/dist/m365/spo/commands/listitem/listitem-roleinheritance-break.js +13 -5
  82. package/dist/m365/spo/commands/listitem/listitem-roleinheritance-reset.js +13 -5
  83. package/dist/m365/spo/commands/listitem/listitem-set.js +52 -44
  84. package/dist/m365/spo/commands/roledefinition/roledefinition-list.js +15 -2
  85. package/dist/m365/spo/commands/site/site-add.js +4 -11
  86. package/dist/m365/spo/commands/{hubsite/hubsite-connect.js → site/site-hubsite-connect.js} +10 -10
  87. package/dist/m365/spo/commands/{hubsite/hubsite-disconnect.js → site/site-hubsite-disconnect.js} +13 -13
  88. package/dist/m365/spo/commands/{hubsite/hubsite-theme-sync.js → site/site-hubsite-theme-sync.js} +11 -11
  89. package/dist/m365/spo/commands/web/web-roleassignment-add.js +10 -10
  90. package/dist/m365/spo/commands/web/web-roleassignment-remove.js +8 -8
  91. package/dist/m365/spo/commands/web/web-roleinheritance-break.js +100 -0
  92. package/dist/m365/spo/commands.js +8 -3
  93. package/dist/m365/teams/commands/channel/channel-add.js +9 -9
  94. package/dist/m365/teams/commands/team/team-set.js +0 -7
  95. package/dist/m365/todo/commands/list/list-get.js +89 -0
  96. package/dist/m365/todo/commands/task/task-add.js +55 -3
  97. package/dist/m365/todo/commands/task/task-get.js +108 -0
  98. package/dist/m365/todo/commands/task/task-set.js +53 -1
  99. package/dist/m365/todo/commands.js +2 -0
  100. package/dist/utils/md.js +8 -1
  101. package/docs/docs/_clisettings.md +18 -0
  102. package/docs/docs/cmd/aad/app/app-list.md +149 -0
  103. package/docs/docs/cmd/aad/user/user-guest-add.md +107 -0
  104. package/docs/docs/cmd/adaptivecard/adaptivecard-send.md +3 -0
  105. package/docs/docs/cmd/graph/schemaextension/schemaextension-add.md +4 -11
  106. package/docs/docs/cmd/graph/schemaextension/schemaextension-set.md +4 -10
  107. package/docs/docs/cmd/outlook/mail/mail-send.md +13 -0
  108. package/docs/docs/cmd/outlook/message/message-get.md +48 -0
  109. package/docs/docs/cmd/planner/bucket/bucket-add.md +29 -0
  110. package/docs/docs/cmd/planner/bucket/bucket-get.md +29 -0
  111. package/docs/docs/cmd/planner/bucket/bucket-list.md +30 -0
  112. package/docs/docs/cmd/planner/bucket/bucket-remove.md +4 -0
  113. package/docs/docs/cmd/planner/bucket/bucket-set.md +4 -0
  114. package/docs/docs/cmd/planner/plan/plan-add.md +123 -0
  115. package/docs/docs/cmd/planner/plan/plan-get.md +75 -6
  116. package/docs/docs/cmd/planner/plan/plan-list.md +45 -0
  117. package/docs/docs/cmd/planner/plan/plan-remove.md +4 -0
  118. package/docs/docs/cmd/planner/task/task-get.md +0 -3
  119. package/docs/docs/cmd/pp/card/card-get.md +51 -0
  120. package/docs/docs/cmd/pp/card/card-list.md +33 -0
  121. package/docs/docs/cmd/pp/card/card-remove.md +82 -0
  122. package/docs/docs/cmd/pp/dataverse/dataverse-table-list.md +2 -2
  123. package/docs/docs/cmd/pp/environment/environment-get.md +38 -0
  124. package/docs/docs/cmd/pp/environment/environment-list.md +1 -1
  125. package/docs/docs/cmd/pp/gateway/gateway-get.md +24 -0
  126. package/docs/docs/cmd/pp/solution/solution-get.md +51 -0
  127. package/docs/docs/cmd/pp/solution/solution-list.md +33 -0
  128. package/docs/docs/cmd/spfx/project/project-rename.md +1 -14
  129. package/docs/docs/cmd/spfx/project/project-upgrade.md +1 -1
  130. package/docs/docs/cmd/spfx/spfx-doctor.md +10 -1
  131. package/docs/docs/cmd/spo/contenttype/contenttype-add.md +20 -2
  132. package/docs/docs/cmd/spo/contenttype/contenttype-field-remove.md +22 -4
  133. package/docs/docs/cmd/spo/contenttype/contenttype-get.md +21 -3
  134. package/docs/docs/cmd/spo/customaction/customaction-add.md +3 -0
  135. package/docs/docs/cmd/spo/customaction/customaction-set.md +3 -2
  136. package/docs/docs/cmd/spo/eventreceiver/eventreceiver-get.md +2 -2
  137. package/docs/docs/cmd/spo/eventreceiver/eventreceiver-remove.md +69 -0
  138. package/docs/docs/cmd/spo/field/field-add.md +20 -2
  139. package/docs/docs/cmd/spo/field/field-set.md +15 -3
  140. package/docs/docs/cmd/spo/file/file-roleinheritance-break.md +54 -0
  141. package/docs/docs/cmd/spo/folder/folder-list.md +45 -0
  142. package/docs/docs/cmd/spo/folder/folder-roleassignment-remove.md +57 -0
  143. package/docs/docs/cmd/spo/folder/folder-roleinheritance-break.md +6 -0
  144. package/docs/docs/cmd/spo/folder/folder-roleinheritance-reset.md +6 -0
  145. package/docs/docs/cmd/spo/group/group-list.md +10 -1
  146. package/docs/docs/cmd/spo/hubsite/hubsite-register.md +2 -2
  147. package/docs/docs/cmd/spo/hubsite/hubsite-unregister.md +2 -2
  148. package/docs/docs/cmd/spo/list/list-contenttype-add.md +15 -6
  149. package/docs/docs/cmd/spo/list/list-contenttype-default-set.md +16 -7
  150. package/docs/docs/cmd/spo/list/list-contenttype-list.md +15 -6
  151. package/docs/docs/cmd/spo/list/list-contenttype-remove.md +16 -7
  152. package/docs/docs/cmd/spo/list/list-roleinheritance-break.md +11 -8
  153. package/docs/docs/cmd/spo/list/list-roleinheritance-reset.md +16 -7
  154. package/docs/docs/cmd/spo/list/list-view-set.md +14 -3
  155. package/docs/docs/cmd/spo/list/list-webhook-add.md +15 -16
  156. package/docs/docs/cmd/spo/list/list-webhook-get.md +16 -7
  157. package/docs/docs/cmd/spo/list/list-webhook-list.md +13 -10
  158. package/docs/docs/cmd/spo/list/list-webhook-remove.md +12 -10
  159. package/docs/docs/cmd/spo/list/list-webhook-set.md +21 -12
  160. package/docs/docs/cmd/spo/listitem/listitem-add.md +11 -2
  161. package/docs/docs/cmd/spo/listitem/listitem-attachment-list.md +11 -2
  162. package/docs/docs/cmd/spo/listitem/listitem-get.md +11 -2
  163. package/docs/docs/cmd/spo/listitem/listitem-isrecord.md +12 -2
  164. package/docs/docs/cmd/spo/listitem/listitem-list.md +10 -1
  165. package/docs/docs/cmd/spo/listitem/listitem-record-declare.md +7 -4
  166. package/docs/docs/cmd/spo/listitem/listitem-record-undeclare.md +11 -2
  167. package/docs/docs/cmd/spo/listitem/listitem-remove.md +11 -2
  168. package/docs/docs/cmd/spo/listitem/listitem-roleassignment-add.md +81 -0
  169. package/docs/docs/cmd/spo/listitem/listitem-roleinheritance-break.md +7 -4
  170. package/docs/docs/cmd/spo/listitem/listitem-roleinheritance-reset.md +8 -5
  171. package/docs/docs/cmd/spo/listitem/listitem-set.md +7 -4
  172. package/docs/docs/cmd/spo/page/page-clientsidewebpart-add.md +5 -10
  173. package/docs/docs/cmd/spo/page/page-control-set.md +2 -1
  174. package/docs/docs/cmd/spo/site/site-add.md +0 -3
  175. package/docs/docs/cmd/spo/{hubsite/hubsite-connect.md → site/site-hubsite-connect.md} +4 -4
  176. package/docs/docs/cmd/spo/{hubsite/hubsite-disconnect.md → site/site-hubsite-disconnect.md} +7 -7
  177. package/docs/docs/cmd/spo/{hubsite/hubsite-theme-sync.md → site/site-hubsite-theme-sync.md} +5 -5
  178. package/docs/docs/cmd/spo/term/term-add.md +5 -0
  179. package/docs/docs/cmd/spo/term/term-set-add.md +6 -1
  180. package/docs/docs/cmd/spo/web/web-roleinheritance-break.md +44 -0
  181. package/docs/docs/cmd/teams/channel/channel-add.md +4 -4
  182. package/docs/docs/cmd/teams/team/team-clone.md +0 -3
  183. package/docs/docs/cmd/teams/team/team-set.md +0 -3
  184. package/docs/docs/cmd/tenant/id/id-get.md +20 -0
  185. package/docs/docs/cmd/tenant/report/report-activeusercounts.md +35 -0
  186. package/docs/docs/cmd/tenant/report/report-activeuserdetail.md +49 -0
  187. package/docs/docs/cmd/tenant/report/report-office365activationcounts.md +32 -0
  188. package/docs/docs/cmd/tenant/report/report-office365activationsusercounts.md +30 -0
  189. package/docs/docs/cmd/tenant/report/report-office365activationsuserdetail.md +36 -0
  190. package/docs/docs/cmd/tenant/report/report-servicesusercounts.md +41 -0
  191. package/docs/docs/cmd/tenant/security/security-alerts-list.md +105 -0
  192. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-health-get.md +87 -0
  193. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-health-list.md +91 -0
  194. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-healthissue-get.md +62 -0
  195. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-healthissue-list.md +51 -0
  196. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-message-get.md +64 -0
  197. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-message-list.md +52 -0
  198. package/docs/docs/cmd/todo/list/list-get.md +61 -0
  199. package/docs/docs/cmd/todo/task/task-add.md +32 -5
  200. package/docs/docs/cmd/todo/task/task-get.md +75 -0
  201. package/docs/docs/cmd/todo/task/task-set.md +29 -2
  202. package/package.json +13 -3
  203. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN006006_CFG_PS_features.js +0 -60
@@ -14,7 +14,13 @@ m365 spo field add [options]
14
14
  : Absolute URL of the site where the field should be created
15
15
 
16
16
  `-l, --listTitle [listTitle]`
17
- : Title of the list where the field should be created (if it should be created as a list column)
17
+ : Title of the list where the field should be created (if it should be created as a list column). Specify either `listTitle`, `listId` or `listUrl`
18
+
19
+ `--listId [listId]`
20
+ : ID of the list where the field should be created (if it should be created as a list column). Specify either `listTitle`, `listId` or `listUrl`
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list where the field should be created (if it should be created as a list column). Specify either `listTitle`, `listId` or `listUrl`
18
24
 
19
25
  `-x, --xml <xml>`
20
26
  : CAML field definition
@@ -36,7 +42,7 @@ Create a date time site column
36
42
  m365 spo field add --webUrl https://contoso.sharepoint.com/sites/contoso-sales --xml '`<Field Type="DateTime" DisplayName="Start date-time" Required="FALSE" EnforceUniqueValues="FALSE" Indexed="FALSE" Format="DateTime" Group="PnP Columns" FriendlyDisplayFormat="Disabled" ID="{5ee2dd25-d941-455a-9bdb-7f2c54aed11b}" SourceID="{4f118c69-66e0-497c-96ff-d7855ce0713d}" StaticName="PnPAlertStartDateTime" Name="PnPAlertStartDateTime"><Default>[today]</Default></Field>`'
37
43
  ```
38
44
 
39
- Create a URL list column
45
+ Create a URL list column to a list retrieved by Title
40
46
 
41
47
  ```sh
42
48
  m365 spo field add --webUrl https://contoso.sharepoint.com/sites/contoso-sales --listTitle Events --xml '`<Field Type="URL" DisplayName="More information link" Required="FALSE" EnforceUniqueValues="FALSE" Indexed="FALSE" Format="Hyperlink" Group="PnP Columns" ID="{6085e32a-339b-4da7-ab6d-c1e013e5ab27}" SourceID="{4f118c69-66e0-497c-96ff-d7855ce0713d}" StaticName="PnPAlertMoreInformation" Name="PnPAlertMoreInformation"></Field>`'
@@ -48,6 +54,18 @@ Create a URL list column and add it to all content types
48
54
  m365 spo field add --webUrl https://contoso.sharepoint.com/sites/contoso-sales --listTitle Events --xml '`<Field Type="URL" DisplayName="More information link" Required="FALSE" EnforceUniqueValues="FALSE" Indexed="FALSE" Format="Hyperlink" Group="PnP Columns" ID="{6085e32a-339b-4da7-ab6d-c1e013e5ab27}" SourceID="{4f118c69-66e0-497c-96ff-d7855ce0713d}" StaticName="PnPAlertMoreInformation" Name="PnPAlertMoreInformation"></Field>`' --options AddToAllContentTypes
49
55
  ```
50
56
 
57
+ Create a URL list column to a list retrieved by ID
58
+
59
+ ```sh
60
+ m365 spo field add --webUrl https://contoso.sharepoint.com/sites/contoso-sales --listId e785fe80-2ca1-409e-b9d1-19055a85cd38 --xml '`<Field Type="URL" DisplayName="More information link" Required="FALSE" EnforceUniqueValues="FALSE" Indexed="FALSE" Format="Hyperlink" Group="PnP Columns" ID="{6085e32a-339b-4da7-ab6d-c1e013e5ab27}" SourceID="{4f118c69-66e0-497c-96ff-d7855ce0713d}" StaticName="PnPAlertMoreInformation" Name="PnPAlertMoreInformation"></Field>`'
61
+ ```
62
+
63
+ Create a date time list column to a list retrieved by URL
64
+
65
+ ```sh
66
+ m365 spo field add --webUrl https://contoso.sharepoint.com/sites/contoso-sales --listUrl /sites/contoso-sales/lists/Events --xml '`<Field Type="DateTime" DisplayName="Start date-time" Required="FALSE" EnforceUniqueValues="FALSE" Indexed="FALSE" Format="DateTime" Group="PnP Columns" FriendlyDisplayFormat="Disabled" ID="{5ee2dd25-d941-455a-9bdb-7f2c54aed11b}" SourceID="{4f118c69-66e0-497c-96ff-d7855ce0713d}" StaticName="PnPAlertStartDateTime" Name="PnPAlertStartDateTime"><Default>[today]</Default></Field>`'
67
+ ```
68
+
51
69
  ## More information
52
70
 
53
71
  - AddFieldOptions enumeration: [https://msdn.microsoft.com/en-us/library/microsoft.sharepoint.client.addfieldoptions.aspx](https://msdn.microsoft.com/en-us/library/microsoft.sharepoint.client.addfieldoptions.aspx)
@@ -14,10 +14,13 @@ m365 spo field set [options]
14
14
  : Absolute URL of the site where the field is located
15
15
 
16
16
  `--listId [listId]`
17
- : ID of the list where the field is located (if list column). Specify `listTitle` or `listId` but not both
17
+ : ID of the list where the field is located (if list column). Specify either `listTitle`, `listId` or `listUrl`
18
18
 
19
19
  `--listTitle [listTitle]`
20
- : Title of the list where the field is located (if list column). Specify `listTitle` or `listId` but not both
20
+ : Title of the list where the field is located (if list column). Specify either `listTitle`, `listId` or `listUrl`
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list where the field is located (if list column). Specify either `listTitle`, `listId` or `listUrl`
21
24
 
22
25
  `-i, --id [id]`
23
26
  : ID of the field to update. Specify `id` or `title` but not both
@@ -34,6 +37,9 @@ m365 spo field set [options]
34
37
 
35
38
  Specify properties to update using their names, eg. `--Title 'New Title' --JSLink jslink.js`.
36
39
 
40
+ !!! warning "Escaping JSON in PowerShell"
41
+ When updating column formatting for a field with the `--CustomFormatter` option, it's possible to enter a JSON string. In PowerShell 5 to 7.2 [specific escaping rules](./../../../user-guide/using-cli.md#escaping-double-quotes-in-powershell) apply due to an issue. Remember that you can also use [file tokens](./../../../user-guide/using-cli.md#passing-complex-content-into-cli-options) instead.
42
+
37
43
  ## Examples
38
44
 
39
45
  Update the title of the site column specified by its internal name and push changes to existing lists
@@ -48,8 +54,14 @@ Update the title of the list column specified by its ID
48
54
  m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'My List' --id 330f29c5-5c4c-465f-9f4b-7903020ae1ce --Title 'My column'
49
55
  ```
50
56
 
57
+ Update the description of a column specified by the ID on a list retrieved by the URL
58
+
59
+ ```sh
60
+ m365 spo field set --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl '/sites/project-x/Lists/My List' --id 330f29c5-5c4c-465f-9f4b-7903020ae1ce --Description 'My column Description'
61
+ ```
62
+
51
63
  Update column formatting of the specified list column
52
64
 
53
65
  ```sh
54
- 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"}`'
66
+ 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
67
  ```
@@ -0,0 +1,54 @@
1
+ # spo file roleinheritance break
2
+
3
+ Breaks inheritance of a file. Keeping existing permissions is the default behavior.
4
+
5
+ ## Usage
6
+
7
+ ```sh
8
+ m365 spo file roleinheritance break [options]
9
+ ```
10
+
11
+ ## Options
12
+
13
+ `-u, --webUrl <webUrl>`
14
+ : URL of the site where the file is located
15
+
16
+ `--fileUrl [fileUrl]`
17
+ : The server-relative URL of the file. Specify either `fileUrl` or `fileId` but not both
18
+
19
+ `i, --fileId [fileId]`
20
+ : The UniqueId (GUID) of the file. Specify either `fileUrl` or `fileId` but not both
21
+
22
+ `-c, --clearExistingPermissions`
23
+ : Clear all existing permissions from the file
24
+
25
+ `--confirm`
26
+ : Don't prompt for confirmation
27
+
28
+ --8<-- "docs/cmd/_global.md"
29
+
30
+ ## Examples
31
+
32
+ Break the inheritance of a file with a specific id (UniqueId).
33
+
34
+ ```sh
35
+ m365 spo file roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --fileId "b2307a39-e878-458b-bc90-03bc578531d6"
36
+ ```
37
+
38
+ Break the inheritance of a file with a specific id (UniqueId) and clear all existing permissions.
39
+
40
+ ```sh
41
+ m365 spo file roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --fileId "b2307a39-e878-458b-bc90-03bc578531d6" --clearExistingPermissions
42
+ ```
43
+
44
+ Break the inheritance of a file with a specific server-relative URL.
45
+
46
+ ```sh
47
+ m365 spo file roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --fileUrl "/sites/project-x/documents/Test1.docx"
48
+ ```
49
+
50
+ Break the inheritance of a file with a specific server-relative URL and clear all existing permissions.
51
+
52
+ ```sh
53
+ m365 spo file roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --fileUrl "/sites/project-x/documents/Test1.docx" --clearExistingPermissions
54
+ ```
@@ -16,6 +16,9 @@ m365 spo folder list [options]
16
16
  `-p, --parentFolderUrl <parentFolderUrl>`
17
17
  : Site-relative URL of the parent folder
18
18
 
19
+ `-r, --recursive`
20
+ : Set to retrieve nested folders
21
+
19
22
  --8<-- "docs/cmd/_global.md"
20
23
 
21
24
  ## Examples
@@ -25,3 +28,45 @@ Gets list of folders under a parent folder with site-relative url _/Shared Docum
25
28
  ```sh
26
29
  m365 spo folder list --webUrl https://contoso.sharepoint.com/sites/project-x --parentFolderUrl '/Shared Documents'
27
30
  ```
31
+
32
+ Gets recursive list of folders under a specific folder on a specific site
33
+
34
+ ```sh
35
+ m365 spo folder list --webUrl https://contoso.sharepoint.com/sites/project-x --parentFolderUrl '/Shared Documents' --recursive
36
+ ```
37
+
38
+ ## Response
39
+
40
+ === "JSON"
41
+
42
+ ```json
43
+ [
44
+ {
45
+ "Exists": true,
46
+ "IsWOPIEnabled": false,
47
+ "ItemCount": 9,
48
+ "Name": "Folder A",
49
+ "ProgID": null,
50
+ "ServerRelativeUrl": "/Shared Documents/Folder A",
51
+ "TimeCreated": "2022-04-26T12:30:56Z",
52
+ "TimeLastModified": "2022-04-26T12:50:14Z",
53
+ "UniqueId": "20523746-971b-4488-aa6d-b45d645f61c5",
54
+ "WelcomePage": ""
55
+ }
56
+ ]
57
+ ```
58
+
59
+ === "Text"
60
+
61
+ ```text
62
+ Name ServerRelativeUrl
63
+ ------- -------------------------
64
+ Folder A /Shared Documents/Folder A
65
+ ```
66
+
67
+ === "CSV"
68
+
69
+ ```csv
70
+ Name,ServerRelativeUrl
71
+ Folder A,/Shared Documents/Folder A
72
+ ```
@@ -0,0 +1,57 @@
1
+ # spo folder roleassignment remove
2
+
3
+ Removes a role assignment from the specified folder.
4
+
5
+ ## Usage
6
+
7
+ ```sh
8
+ m365 spo folder roleassignment remove [options]
9
+ ```
10
+
11
+ ## Options
12
+
13
+ `-u, --webUrl <webUrl>`
14
+ : The URL of the site where the folder is located.
15
+
16
+ `-f, --folderUrl <folderUrl>`
17
+ : The server- or site-relative URL of the folder.
18
+
19
+ `--principalId [principalId]`
20
+ : The SharePoint principal id. It may be either an user id or group id for which the role assignment will be removed. Specify either upn, groupName or principalId but not multiple.
21
+
22
+ `--upn [upn]`
23
+ : The upn/email of the user. Specify either upn, groupName or principalId but not multiple.
24
+
25
+ `--groupName [groupName]`
26
+ : The Azure AD or SharePoint group name. Specify either upn, groupName or principalId but not multiple.
27
+
28
+ `--confirm`
29
+ : Don't prompt for confirmation when removing the role assignment.
30
+
31
+ --8<-- "docs/cmd/_global.md"
32
+
33
+ ## Examples
34
+
35
+ Remove roleassignment from folder based on group name
36
+
37
+ ```sh
38
+ m365 spo folder roleassignment remove --webUrl "https://contoso.sharepoint.com/sites/contoso-sales" --folderUrl "/Shared Documents/FolderPermission" --groupName "saleGroup"
39
+ ```
40
+
41
+ Remove the role assignment from the specified folder based on the principal id.
42
+
43
+ ```sh
44
+ m365 spo folder roleassignment remove --webUrl "https://contoso.sharepoint.com/sites/contoso-sales" --folderUrl "/Shared Documents/FolderPermission" --principalId 2
45
+ ```
46
+
47
+ Remove the role assignment from the specified folder based on the principal id without prompting for removal confirmation.
48
+
49
+ ```sh
50
+ m365 spo folder roleassignment remove --webUrl "https://contoso.sharepoint.com/sites/contoso-sales" --folderUrl "/Shared Documents/FolderPermission" --principalId 2 --confirm
51
+ ```
52
+
53
+ Remove the role assignment from the specified folder based on the upn.
54
+
55
+ ```sh
56
+ m365 spo folder roleassignment remove --webUrl "https://contoso.sharepoint.com/sites/contoso-sales" --folderUrl "/Shared Documents/FolderPermission" --upn "test@contoso.onmicrosoft.com"
57
+ ```
@@ -37,3 +37,9 @@ Break the inheritance of a folder with a specified server-relative URL. It will
37
37
  ```sh
38
38
  m365 spo folder roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --folderUrl "/sites/project-x/Shared Documents/TestFolder" --clearExistingPermissions --confirm
39
39
  ```
40
+
41
+ Break the inheritance of the specified root folder for the library with a specified server-relative URL. It will clear the existing permissions of the root folder. It will **not** prompt for confirmation before breaking the inheritance.
42
+
43
+ ```sh
44
+ m365 spo folder roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --folderUrl "/sites/project-x/Shared Documents" --clearExistingPermissions --confirm
45
+ ```
@@ -34,3 +34,9 @@ Reset inheritance of folder with server-relative url _/sites/project-x/Shared Do
34
34
  ```sh
35
35
  m365 spo folder roleinheritance reset --webUrl "https://contoso.sharepoint.com/sites/project-x" --folderUrl "/sites/project-x/Shared Documents/TestFolder" --confirm
36
36
  ```
37
+
38
+ Reset inheritance of the specified root folder for the library with the server-relative url _/sites/project-x/Shared Documents located in site _https://contoso.sharepoint.com/sites/project-x_. It will **not** prompt for confirmation before resetting.
39
+
40
+ ```sh
41
+ m365 spo folder roleinheritance reset --webUrl "https://contoso.sharepoint.com/sites/project-x" --folderUrl "/sites/project-x/Shared Documents" --confirm
42
+ ```
@@ -13,12 +13,21 @@ m365 spo group list [options]
13
13
  `-u, --webUrl <webUrl>`
14
14
  : Url of the web to list the group within
15
15
 
16
+ `--associatedGroupsOnly`
17
+ : Get only the associated visitor, member and owner groups of the site.
18
+
16
19
  --8<-- "docs/cmd/_global.md"
17
20
 
18
21
  ## Examples
19
22
 
20
- Lists all the groups within specific web _https://contoso.sharepoint.com/sites/contoso_
23
+ Lists all the groups within a specific web
21
24
 
22
25
  ```sh
23
26
  m365 spo group list --webUrl "https://contoso.sharepoint.com/sites/contoso"
24
27
  ```
28
+
29
+ Lists the associated groups within a specific web
30
+
31
+ ```sh
32
+ m365 spo group list --webUrl "https://contoso.sharepoint.com/sites/contoso" --associatedGroupsOnly
33
+ ```
@@ -17,8 +17,8 @@ m365 spo hubsite register [options]
17
17
 
18
18
  ## Remarks
19
19
 
20
- !!! attention
21
- This command is based on a SharePoint API that is currently in preview and is subject to change once the API reached general availability.
20
+ !!! important
21
+ To use this command you must be a Global or SharePoint administrator.
22
22
 
23
23
  If the specified site collection is already registered as a hub site, you will get a `This site is already a HubSite.` error.
24
24
 
@@ -20,8 +20,8 @@ m365 spo hubsite unregister [options]
20
20
 
21
21
  ## Remarks
22
22
 
23
- !!! attention
24
- This command is based on a SharePoint API that is currently in preview and is subject to change once the API reached general availability.
23
+ !!! important
24
+ To use this command you must be a Global or SharePoint administrator.
25
25
 
26
26
  If the specified site collection is not registered as a hub site, you will get a `hubSiteId` error.
27
27
 
@@ -11,13 +11,16 @@ m365 spo list contenttype add [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list is located
14
+ : URL of the site where the list is located.
15
15
 
16
- `-l, --listId [listId]`
17
- : ID of the list to which to add the content type. Specify `listId` or `listTitle` but not both
16
+ `-i, --listId [listId]`
17
+ : ID of the list. Specify either `listTitle`, `listId` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list to which to add the content type. Specify `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
24
 
22
25
  `-i, --id <id>`
23
26
  : ID of the content type to add to the list
@@ -26,14 +29,20 @@ m365 spo list contenttype add [options]
26
29
 
27
30
  ## Examples
28
31
 
29
- Add existing content type with ID _0x0120_ to the list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
32
+ Adds a specific existing content type to a list retrieved by id in a specific site.
30
33
 
31
34
  ```sh
32
35
  m365 spo list contenttype add --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf --id 0x0120
33
36
  ```
34
37
 
35
- Add existing content type with ID _0x0120_ to the list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/project-x_
38
+ Adds a specific existing content type to a list retrieved by title in a specific site.
36
39
 
37
40
  ```sh
38
41
  m365 spo list contenttype add --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle Documents --id 0x0120
39
42
  ```
43
+
44
+ Adds a specific existing content type to a list retrieved by server relative URL in a specific site.
45
+
46
+ ```sh
47
+ m365 spo list contenttype add --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl 'sites/project-x/Documents' --contentTypeId 0x0120
48
+ ```
@@ -11,29 +11,38 @@ m365 spo list contenttype default set [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list is located
14
+ : URL of the site where the list is located.
15
15
 
16
- `-l, --listId [listId]`
17
- : ID of the list on which to set default content type, specify `listId` or `listTitle` but not both
16
+ `-i, --listId [listId]`
17
+ : ID of the list. Specify either `listTitle`, `listId` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list on which to set default content type, specify `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
24
 
22
25
  `-c, --contentTypeId <contentTypeId>`
23
- : ID of the content type to set as default on the list
26
+ : ID of the content type
24
27
 
25
28
  --8<-- "docs/cmd/_global.md"
26
29
 
27
30
  ## Examples
28
31
 
29
- Set content type with ID _0x0120_ as default in the list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
32
+ Set a content type with a specific id as default a list retrieved by id located in a specific site.
30
33
 
31
34
  ```sh
32
35
  m365 spo list contenttype default set --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf --contentTypeId 0x0120
33
36
  ```
34
37
 
35
- Set content type with ID _0x0120_ as default in the list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/project-x_
38
+ Set a content type with a specific id as default a list retrieved by title located in a specific site.
36
39
 
37
40
  ```sh
38
41
  m365 spo list contenttype default set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle Documents --contentTypeId 0x0120
39
42
  ```
43
+
44
+ Set a content type with a specific id as default a list retrieved by server relative URL located in a specific site.
45
+
46
+ ```sh
47
+ m365 spo list contenttype default set --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl 'sites/project-x/Documents' --contentTypeId 0x0120
48
+ ```
@@ -11,26 +11,35 @@ m365 spo list contenttype list [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list is located
14
+ : URL of the site where the list is located.
15
15
 
16
- `-l, --listId [listId]`
17
- : ID of the list for which to list configured content types. Specify `listId` or `listTitle` but not both
16
+ `-i, --listId [listId]`
17
+ : ID of the list. Specify either `listTitle`, `listId` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list for which to list configured content types. Specify `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
24
 
22
25
  --8<-- "docs/cmd/_global.md"
23
26
 
24
27
  ## Examples
25
28
 
26
- List all content types configured on the list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
29
+ List all content types configured on a specific list retrieved by id in a specific site.
27
30
 
28
31
  ```sh
29
32
  m365 spo list contenttype list --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf
30
33
  ```
31
34
 
32
- List all content types configured on the list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/project-x_
35
+ List all content types configured on a specific list retrieved by title in a specific site.
33
36
 
34
37
  ```sh
35
38
  m365 spo list contenttype list --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle Documents
36
39
  ```
40
+
41
+ List all content types configured on a specific list retrieved by server relative URL in a specific site.
42
+
43
+ ```sh
44
+ m365 spo list contenttype list --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl 'sites/project-x/Documents'
45
+ ```
@@ -11,32 +11,41 @@ m365 spo list contenttype remove [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list is located
14
+ : URL of the site where the list is located.
15
15
 
16
- `-l, --listId [listId]`
17
- : ID of the list from which to remove the content type, specify `listId` or `listTitle` but not both
16
+ `-i, --listId [listId]`
17
+ : ID of the list. Specify either `listTitle`, `listId` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list from which to remove the content type, specify `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
24
 
22
25
  `-i, --id <id>`
23
26
  : ID of the content type to remove from the list
24
27
 
25
28
  `--confirm`
26
- : Don't prompt for confirming removing the content type from the list
29
+ : Don't prompt for confirmation
27
30
 
28
31
  --8<-- "docs/cmd/_global.md"
29
32
 
30
33
  ## Examples
31
34
 
32
- Remove content type with ID _0x010109010053EE7AEB1FC54A41B4D9F66ADBDC312A_ from the list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
35
+ Remove content type with a specific id from the list retrieved by id in a specific site.
33
36
 
34
37
  ```sh
35
38
  m365 spo list contenttype remove --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf --id 0x010109010053EE7AEB1FC54A41B4D9F66ADBDC312A
36
39
  ```
37
40
 
38
- Remove content type with ID _0x010109010053EE7AEB1FC54A41B4D9F66ADBDC312A_ from the list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/project-x_
41
+ Remove content type with a specific id from the list retrieved by title in a specific site.
39
42
 
40
43
  ```sh
41
44
  m365 spo list contenttype remove --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle Documents --id 0x010109010053EE7AEB1FC54A41B4D9F66ADBDC312A
42
45
  ```
46
+
47
+ Remove content type with a specific id from the list retrieved by server relative URL in a specific site. This will not prompt for confirmation.
48
+
49
+ ```sh
50
+ m365 spo list contenttype remove --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl 'sites/project-x/Documents' --contentTypeId 0x010109010053EE7AEB1FC54A41B4D9F66ADBDC312A --confirm
51
+ ```
@@ -11,13 +11,16 @@ m365 spo list roleinheritance break [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list to retrieve is located
14
+ : URL of the site where the list is located.
15
15
 
16
16
  `-i, --listId [listId]`
17
- : ID of the list to retrieve information for. Specify either id or title but not both
17
+ : ID of the list. Specify either `listTitle`, `listId` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list to retrieve information for. Specify either id or title but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
24
 
22
25
  `-c, --clearExistingPermissions`
23
26
  : Flag if used clears all roles from the list
@@ -33,28 +36,28 @@ By default, when breaking permissions inheritance, the list will retain existing
33
36
 
34
37
  ## Examples
35
38
 
36
- Break inheritance of list _someList_ located in site _https://contoso.sharepoint.com/sites/project-x_
39
+ Break inheritance of list by title in a specific site
37
40
 
38
41
  ```sh
39
42
  m365 spo list roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listTitle "someList"
40
43
  ```
41
44
 
42
- Break inheritance of list with ID _202b8199-b9de-43fd-9737-7f213f51c991_ located in site _https://contoso.sharepoint.com/sites/project-x_
45
+ Break inheritance of list by id in a specific site
43
46
 
44
47
  ```sh
45
48
  m365 spo list roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listId "202b8199-b9de-43fd-9737-7f213f51c991"
46
49
  ```
47
50
 
48
- Break inheritance of list _someList_ located in site _https://contoso.sharepoint.com/sites/project-x_ with clearing permissions
51
+ Break inheritance of list by title located in a specific site and clearing the existing permissions
49
52
 
50
53
  ```sh
51
54
  m365 spo list roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listTitle "someList" --clearExistingPermissions
52
55
  ```
53
56
 
54
- Break inheritance of list with ID _202b8199-b9de-43fd-9737-7f213f51c991_ located in site _https://contoso.sharepoint.com/sites/project-x_ with clearing permissions
57
+ Break inheritance of list by url in a specific site and clearing the existing permissions
55
58
 
56
59
  ```sh
57
- m365 spo list roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listId "202b8199-b9de-43fd-9737-7f213f51c991" --clearExistingPermissions
60
+ m365 spo list roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listUrl '/sites/project-x/lists/events' --clearExistingPermissions
58
61
  ```
59
62
 
60
63
  Break inheritance of list with ID _202b8199-b9de-43fd-9737-7f213f51c991_ located in site _https://contoso.sharepoint.com/sites/project-x_ with clearing permissions without prompting for confirmation
@@ -11,13 +11,16 @@ m365 spo list roleinheritance reset [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list is located
14
+ : URL of the site where the list is located.
15
15
 
16
16
  `-i, --listId [listId]`
17
- : ID of the list. Specify either id or title but not both
17
+ : ID of the list. Specify either `listTitle`, `listId` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list. Specify either id or title but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
24
 
22
25
  `--confirm`
23
26
  : Do not prompt for confirmation before resetting role inheritance.
@@ -26,20 +29,26 @@ m365 spo list roleinheritance reset [options]
26
29
 
27
30
  ## Examples
28
31
 
29
- Restore role inheritance of list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
32
+ Restores role inheritance of a specific list by id in a specific site
30
33
 
31
34
  ```sh
32
35
  m365 spo list roleinheritance reset --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf
33
36
  ```
34
37
 
35
- Restore role inheritance of list with title _test_ located in site _https://contoso.sharepoint.com/sites/project-x_
38
+ Restores role inheritance of a specific list by title in a specific site
36
39
 
37
40
  ```sh
38
41
  m365 spo list roleinheritance reset --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle test
39
42
  ```
40
43
 
41
- Restore role inheritance of list with title _test_ located in site _https://contoso.sharepoint.com/sites/project-x_ without prompting for confirmation
44
+ Restores role inheritance of a specific list by url in a specific site
45
+
46
+ ```sh
47
+ m365 spo list roleinheritance reset --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl '/sites/project-x/lists/events'
48
+ ```
49
+
50
+ Restores role inheritance of list a specific list by title without prompting for confirmation
42
51
 
43
52
  ```sh
44
53
  m365 spo list roleinheritance reset --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle test --confirm
45
- ```
54
+ ```
@@ -33,6 +33,9 @@ Specify properties to update using their names, eg. `--Title 'New Title' --JSLin
33
33
 
34
34
  When updating list formatting, the value of the CustomFormatter property must be XML-escaped, eg. `&lt;` instead of `<`.
35
35
 
36
+ !!! warning "Escaping JSON in PowerShell"
37
+ When updating list view formatting for a view with the `--CustomFormatter` option, it's possible to enter a JSON string. In PowerShell 5 to 7.2 [specific escaping rules](./../../../user-guide/using-cli.md#escaping-double-quotes-in-powershell) apply due to an issue. Remember that you can also use [file tokens](./../../../user-guide/using-cli.md#passing-complex-content-into-cli-options) instead.
38
+
36
39
  ## Examples
37
40
 
38
41
  Update the title of the list view specified by its name
@@ -49,6 +52,14 @@ m365 spo list view set --webUrl https://contoso.sharepoint.com/sites/project-x -
49
52
 
50
53
  Update view formatting of the specified list view
51
54
 
52
- ```sh
53
- m365 spo list view set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'My List' --title 'All items' --CustomFormatter '`{"schema":"https://developer.microsoft.com/json-schemas/sp/view-formatting.schema.json","additionalRowClass": "=if([$DueDate] &lt;= @now, 'sp-field-severity--severeWarning', '')"}`'
54
- ```
55
+ === "PowerShell"
56
+
57
+ ```sh
58
+ m365 spo list view set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'My List' --viewTitle 'All items' --CustomFormatter '{\"schema\":\"https://developer.microsoft.com/json-schemas/sp/view-formatting.schema.json\",\"additionalRowClass\": \"=if([$DueDate] &lt;= @now, ''sp-field-severity--severeWarning'', '''')\"}'
59
+ ```
60
+
61
+ === "Bash"
62
+
63
+ ```sh
64
+ m365 spo list view set --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'My List' --viewTitle 'All items' --CustomFormatter "{\"schema\":\"https://developer.microsoft.com/json-schemas/sp/view-formatting.schema.json\",\"additionalRowClass\": \"=if([$DueDate] &lt;= @now, 'sp-field-severity--severeWarning', '')\"}"
65
+ ```