@pnp/cli-microsoft365 6.0.0-beta.a008afc → 6.0.0-beta.a2ec37b

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 (161) hide show
  1. package/.eslintrc.js +4 -2
  2. package/dist/Command.js +16 -2
  3. package/dist/m365/aad/commands/app/app-add.js +36 -13
  4. package/dist/m365/aad/commands/app/app-list.js +38 -0
  5. package/dist/m365/aad/commands/user/user-guest-add.js +103 -0
  6. package/dist/m365/aad/commands.js +2 -0
  7. package/dist/m365/commands/status.js +6 -1
  8. package/dist/m365/outlook/commands/mail/mail-send.js +55 -31
  9. package/dist/m365/outlook/commands/message/message-get.js +97 -0
  10. package/dist/m365/outlook/commands.js +1 -0
  11. package/dist/m365/planner/commands/bucket/bucket-get.js +1 -1
  12. package/dist/m365/planner/commands/plan/plan-get.js +5 -20
  13. package/dist/m365/pp/commands/card/card-get.js +110 -0
  14. package/dist/m365/pp/commands/card/card-remove.js +130 -0
  15. package/dist/m365/pp/commands/gateway/gateway-get.js +70 -0
  16. package/dist/m365/pp/commands/solution/solution-get.js +117 -0
  17. package/dist/m365/pp/commands.js +4 -0
  18. package/dist/m365/spfx/commands/project/project-doctor.js +4 -1
  19. package/dist/m365/spfx/commands/project/project-externalize.js +4 -1
  20. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010001_YORC_version.js +2 -1
  21. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010002_YORC_isCreatingSolution.js +2 -1
  22. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010003_YORC_packageManager.js +2 -1
  23. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010004_YORC_componentType.js +2 -1
  24. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010005_YORC_environment.js +2 -1
  25. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010006_YORC_framework.js +3 -2
  26. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010007_YORC_isDomainIsolated.js +2 -1
  27. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010008_YORC_nodeVersion.js +2 -1
  28. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010009_YORC_sdkVersions_microsoft_graph_client.js +56 -0
  29. package/dist/m365/spfx/commands/project/project-upgrade/rules/FN010010_YORC_sdkVersions_teams_js.js +56 -0
  30. package/dist/m365/spfx/commands/project/project-upgrade/{upgrade-1.16.0-beta.1.js → upgrade-1.16.0-beta.2.js} +44 -28
  31. package/dist/m365/spfx/commands/project/project-upgrade.js +1 -1
  32. package/dist/m365/spfx/commands/spfx-doctor.js +3 -3
  33. package/dist/m365/spo/commands/contenttype/contenttype-add.js +82 -43
  34. package/dist/m365/spo/commands/contenttype/contenttype-field-remove.js +53 -21
  35. package/dist/m365/spo/commands/contenttype/contenttype-get.js +35 -14
  36. package/dist/m365/spo/commands/field/field-add.js +26 -1
  37. package/dist/m365/spo/commands/field/field-set.js +23 -13
  38. package/dist/m365/spo/commands/folder/folder-list.js +35 -12
  39. package/dist/m365/spo/commands/folder/folder-roleinheritance-break.js +11 -1
  40. package/dist/m365/spo/commands/folder/folder-roleinheritance-reset.js +12 -1
  41. package/dist/m365/spo/commands/list/list-roleassignment-add.js +1 -1
  42. package/dist/m365/spo/commands/list/list-roleinheritance-break.js +14 -6
  43. package/dist/m365/spo/commands/list/list-roleinheritance-reset.js +14 -6
  44. package/dist/m365/spo/commands/list/list-webhook-add.js +19 -11
  45. package/dist/m365/spo/commands/list/list-webhook-get.js +17 -10
  46. package/dist/m365/spo/commands/list/list-webhook-list.js +17 -42
  47. package/dist/m365/spo/commands/list/list-webhook-remove.js +19 -11
  48. package/dist/m365/spo/commands/list/list-webhook-set.js +27 -20
  49. package/dist/m365/spo/commands/listitem/listitem-add.js +24 -14
  50. package/dist/m365/spo/commands/listitem/listitem-attachment-list.js +18 -8
  51. package/dist/m365/spo/commands/listitem/listitem-get.js +18 -8
  52. package/dist/m365/spo/commands/listitem/listitem-isrecord.js +20 -10
  53. package/dist/m365/spo/commands/listitem/listitem-list.js +21 -11
  54. package/dist/m365/spo/commands/listitem/listitem-record-declare.js +19 -12
  55. package/dist/m365/spo/commands/listitem/listitem-record-undeclare.js +24 -21
  56. package/dist/m365/spo/commands/listitem/listitem-remove.js +19 -11
  57. package/dist/m365/spo/commands/listitem/listitem-roleassignment-add.js +239 -0
  58. package/dist/m365/spo/commands/listitem/listitem-roleinheritance-break.js +13 -5
  59. package/dist/m365/spo/commands/listitem/listitem-roleinheritance-reset.js +13 -5
  60. package/dist/m365/spo/commands/listitem/listitem-set.js +52 -44
  61. package/dist/m365/spo/commands/roledefinition/roledefinition-list.js +15 -2
  62. package/dist/m365/spo/commands/site/site-add.js +4 -11
  63. package/dist/m365/spo/commands/{hubsite/hubsite-connect.js → site/site-hubsite-connect.js} +10 -10
  64. package/dist/m365/spo/commands/{hubsite/hubsite-disconnect.js → site/site-hubsite-disconnect.js} +13 -13
  65. package/dist/m365/spo/commands/{hubsite/hubsite-theme-sync.js → site/site-hubsite-theme-sync.js} +11 -11
  66. package/dist/m365/spo/commands/web/web-roleinheritance-break.js +100 -0
  67. package/dist/m365/spo/commands.js +5 -3
  68. package/dist/m365/teams/commands/team/team-set.js +0 -7
  69. package/dist/m365/todo/commands/list/list-get.js +89 -0
  70. package/dist/m365/todo/commands/task/task-add.js +55 -3
  71. package/dist/m365/todo/commands/task/task-get.js +108 -0
  72. package/dist/m365/todo/commands/task/task-set.js +53 -1
  73. package/dist/m365/todo/commands.js +2 -0
  74. package/docs/docs/_clisettings.md +18 -0
  75. package/docs/docs/cmd/aad/app/app-list.md +149 -0
  76. package/docs/docs/cmd/aad/user/user-guest-add.md +107 -0
  77. package/docs/docs/cmd/adaptivecard/adaptivecard-send.md +3 -0
  78. package/docs/docs/cmd/graph/schemaextension/schemaextension-add.md +4 -11
  79. package/docs/docs/cmd/graph/schemaextension/schemaextension-set.md +4 -10
  80. package/docs/docs/cmd/outlook/mail/mail-send.md +13 -0
  81. package/docs/docs/cmd/outlook/message/message-get.md +48 -0
  82. package/docs/docs/cmd/planner/bucket/bucket-add.md +29 -0
  83. package/docs/docs/cmd/planner/bucket/bucket-get.md +29 -0
  84. package/docs/docs/cmd/planner/bucket/bucket-list.md +30 -0
  85. package/docs/docs/cmd/planner/bucket/bucket-remove.md +4 -0
  86. package/docs/docs/cmd/planner/bucket/bucket-set.md +4 -0
  87. package/docs/docs/cmd/planner/plan/plan-add.md +123 -0
  88. package/docs/docs/cmd/planner/plan/plan-get.md +75 -6
  89. package/docs/docs/cmd/planner/plan/plan-list.md +45 -0
  90. package/docs/docs/cmd/planner/plan/plan-remove.md +4 -0
  91. package/docs/docs/cmd/planner/task/task-get.md +0 -3
  92. package/docs/docs/cmd/pp/card/card-get.md +51 -0
  93. package/docs/docs/cmd/pp/card/card-remove.md +82 -0
  94. package/docs/docs/cmd/pp/gateway/gateway-get.md +24 -0
  95. package/docs/docs/cmd/pp/solution/solution-get.md +51 -0
  96. package/docs/docs/cmd/spfx/project/project-rename.md +1 -14
  97. package/docs/docs/cmd/spfx/project/project-upgrade.md +1 -1
  98. package/docs/docs/cmd/spo/contenttype/contenttype-add.md +20 -2
  99. package/docs/docs/cmd/spo/contenttype/contenttype-field-remove.md +22 -4
  100. package/docs/docs/cmd/spo/contenttype/contenttype-get.md +21 -3
  101. package/docs/docs/cmd/spo/customaction/customaction-add.md +3 -0
  102. package/docs/docs/cmd/spo/customaction/customaction-set.md +3 -2
  103. package/docs/docs/cmd/spo/eventreceiver/eventreceiver-get.md +2 -2
  104. package/docs/docs/cmd/spo/eventreceiver/eventreceiver-remove.md +2 -2
  105. package/docs/docs/cmd/spo/field/field-add.md +20 -2
  106. package/docs/docs/cmd/spo/field/field-set.md +15 -3
  107. package/docs/docs/cmd/spo/folder/folder-list.md +45 -0
  108. package/docs/docs/cmd/spo/folder/folder-roleinheritance-break.md +6 -0
  109. package/docs/docs/cmd/spo/folder/folder-roleinheritance-reset.md +6 -0
  110. package/docs/docs/cmd/spo/hubsite/hubsite-register.md +2 -2
  111. package/docs/docs/cmd/spo/hubsite/hubsite-unregister.md +2 -2
  112. package/docs/docs/cmd/spo/list/list-roleinheritance-break.md +11 -8
  113. package/docs/docs/cmd/spo/list/list-roleinheritance-reset.md +16 -7
  114. package/docs/docs/cmd/spo/list/list-view-set.md +14 -3
  115. package/docs/docs/cmd/spo/list/list-webhook-add.md +15 -16
  116. package/docs/docs/cmd/spo/list/list-webhook-get.md +16 -7
  117. package/docs/docs/cmd/spo/list/list-webhook-list.md +13 -10
  118. package/docs/docs/cmd/spo/list/list-webhook-remove.md +12 -10
  119. package/docs/docs/cmd/spo/list/list-webhook-set.md +21 -12
  120. package/docs/docs/cmd/spo/listitem/listitem-add.md +11 -2
  121. package/docs/docs/cmd/spo/listitem/listitem-attachment-list.md +11 -2
  122. package/docs/docs/cmd/spo/listitem/listitem-get.md +11 -2
  123. package/docs/docs/cmd/spo/listitem/listitem-isrecord.md +12 -2
  124. package/docs/docs/cmd/spo/listitem/listitem-list.md +10 -1
  125. package/docs/docs/cmd/spo/listitem/listitem-record-declare.md +7 -4
  126. package/docs/docs/cmd/spo/listitem/listitem-record-undeclare.md +11 -2
  127. package/docs/docs/cmd/spo/listitem/listitem-remove.md +11 -2
  128. package/docs/docs/cmd/spo/listitem/listitem-roleassignment-add.md +81 -0
  129. package/docs/docs/cmd/spo/listitem/listitem-roleinheritance-break.md +7 -4
  130. package/docs/docs/cmd/spo/listitem/listitem-roleinheritance-reset.md +8 -5
  131. package/docs/docs/cmd/spo/listitem/listitem-set.md +7 -4
  132. package/docs/docs/cmd/spo/page/page-clientsidewebpart-add.md +5 -10
  133. package/docs/docs/cmd/spo/page/page-control-set.md +2 -1
  134. package/docs/docs/cmd/spo/site/site-add.md +0 -3
  135. package/docs/docs/cmd/spo/{hubsite/hubsite-connect.md → site/site-hubsite-connect.md} +4 -4
  136. package/docs/docs/cmd/spo/{hubsite/hubsite-disconnect.md → site/site-hubsite-disconnect.md} +7 -7
  137. package/docs/docs/cmd/spo/{hubsite/hubsite-theme-sync.md → site/site-hubsite-theme-sync.md} +5 -5
  138. package/docs/docs/cmd/spo/term/term-add.md +5 -0
  139. package/docs/docs/cmd/spo/term/term-set-add.md +6 -1
  140. package/docs/docs/cmd/spo/web/web-roleinheritance-break.md +44 -0
  141. package/docs/docs/cmd/teams/team/team-clone.md +0 -3
  142. package/docs/docs/cmd/teams/team/team-set.md +0 -3
  143. package/docs/docs/cmd/tenant/id/id-get.md +20 -0
  144. package/docs/docs/cmd/tenant/report/report-activeusercounts.md +35 -0
  145. package/docs/docs/cmd/tenant/report/report-activeuserdetail.md +49 -0
  146. package/docs/docs/cmd/tenant/report/report-office365activationcounts.md +32 -0
  147. package/docs/docs/cmd/tenant/report/report-office365activationsusercounts.md +30 -0
  148. package/docs/docs/cmd/tenant/report/report-office365activationsuserdetail.md +36 -0
  149. package/docs/docs/cmd/tenant/report/report-servicesusercounts.md +41 -0
  150. package/docs/docs/cmd/tenant/security/security-alerts-list.md +105 -0
  151. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-health-get.md +87 -0
  152. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-health-list.md +91 -0
  153. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-healthissue-get.md +62 -0
  154. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-healthissue-list.md +51 -0
  155. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-message-get.md +64 -0
  156. package/docs/docs/cmd/tenant/serviceannouncement/serviceannouncement-message-list.md +52 -0
  157. package/docs/docs/cmd/todo/list/list-get.md +61 -0
  158. package/docs/docs/cmd/todo/task/task-add.md +32 -5
  159. package/docs/docs/cmd/todo/task/task-get.md +75 -0
  160. package/docs/docs/cmd/todo/task/task-set.md +29 -2
  161. package/package.json +13 -4
@@ -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
+ ```
@@ -11,46 +11,45 @@ m365 spo list webhook add [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list to add the webhook to is located
14
+ : URL of the site where the list is located.
15
15
 
16
16
  `-l, --listId [listId]`
17
- : ID of the list to which the webhook which should be added. Specify either `listId` or `listTitle` 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 which the webhook which should be added. Specify either `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
  `-n, --notificationUrl <notificationUrl>`
23
- : The notification url
26
+ : The notification URL.
24
27
 
25
28
  `-e, --expirationDateTime [expirationDateTime]`
26
- : The expiration date. Will be set to max (6 months from today) if not provided
29
+ : The expiration date. Will be set to max (6 months from today) if not provided.
27
30
 
28
31
  `-c, --clientState [clientState]`
29
- : A client state information that will be passed through notifications
32
+ : A client state information that will be passed through notifications.
30
33
 
31
34
  --8<-- "docs/cmd/_global.md"
32
35
 
33
36
  ## Examples
34
37
 
35
- Add a web hook to the list Documents located in site _https://contoso.sharepoint.com/sites/ninja_ with the notification url
36
- _https://contoso-funcions.azurewebsites.net/webhook_ and the default expiration
37
- date
38
+ Add a web hook to the list retrieved by Title located in a specific site with a specific notification url and the default expiration date
38
39
 
39
40
  ```sh
40
41
  m365 spo list webhook add --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --notificationUrl https://contoso-funcions.azurewebsites.net/webhook
41
42
  ```
42
43
 
43
- Add a web hook to the list Documents located in site _https://contoso.sharepoint.com/sites/ninja_ with the notification url
44
- _https://contoso-funcions.azurewebsites.net/webhook_ and an expiration date of _January 21st, 2019_
44
+ Add a web hook to the list retrieved by URL located in a specific site with a specific notification url and a specific expiration date
45
45
 
46
46
  ```sh
47
- m365 spo list webhook add --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --notificationUrl https://contoso-funcions.azurewebsites.net/webhook --expirationDateTime 2019-01-21
47
+ m365 spo list webhook add --webUrl https://contoso.sharepoint.com/sites/ninja --listUrl '/sites/ninja/Documents' --notificationUrl https://contoso-funcions.azurewebsites.net/webhook --expirationDateTime 2019-01-21
48
48
  ```
49
49
 
50
- Add a web hook to the list Documents located in site _https://contoso.sharepoint.com/sites/ninja_ with the notification url
51
- _https://contoso-funcions.azurewebsites.net/webhook_, a very specific expiration date of _6:15 PM on March 2nd, 2019_ and
52
- a client state
50
+ Add a web hook to the list retrieved by ID located in a specific site with a specific notification url, a specific expiration date and a client state
51
+
53
52
 
54
53
  ```sh
55
- m365 spo list webhook add --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --notificationUrl https://contoso-funcions.azurewebsites.net/webhook --expirationDateTime '2019-03-02T18:15' --clientState "Hello State!"
54
+ m365 spo list webhook add --webUrl https://contoso.sharepoint.com/sites/ninja --listId '3d6aefa0-f438-4789-b0cd-6e865f5d65b5' --notificationUrl https://contoso-funcions.azurewebsites.net/webhook --expirationDateTime '2019-03-02T18:15' --clientState "Hello State!"
56
55
  ```
@@ -11,16 +11,19 @@ m365 spo list webhook get [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list to retrieve the webhook info for is located
14
+ : URL of the site where the list is located.
15
15
 
16
16
  `-l, --listId [listId]`
17
- : ID of the list from which to retrieve the webhook. Specify either `listId` or `listTitle` 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 from which to retrieve the webhook. Specify either `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
21
 
22
- `-i, --id [id]`
23
- : ID of the webhook to retrieve
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
24
+
25
+ `-i, --id <id>`
26
+ : ID of the webhook.
24
27
 
25
28
  --8<-- "docs/cmd/_global.md"
26
29
 
@@ -30,14 +33,20 @@ If the specified `id` doesn't refer to an existing webhook, you will get a `404
30
33
 
31
34
  ## Examples
32
35
 
33
- Return information about a webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e85_ which belongs to a list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
36
+ Return information about a specific webhook which belongs to a list retrieved by ID in a specific site
34
37
 
35
38
  ```sh
36
39
  m365 spo list webhook get --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf --id cc27a922-8224-4296-90a5-ebbc54da2e85
37
40
  ```
38
41
 
39
- Return information about a webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e85_ which belongs to a list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/project-x_
42
+ Return information about a specific webhook which belongs to a list retrieved by Title in a specific site
40
43
 
41
44
  ```sh
42
45
  m365 spo list webhook get --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle Documents --id cc27a922-8224-4296-90a5-ebbc54da2e85
43
46
  ```
47
+
48
+ Return information about a specific webhook which belongs to a list retrieved by URL in a specific site
49
+
50
+ ```sh
51
+ m365 spo list webhook get --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl '/sites/project-x/Documents' --id cc27a922-8224-4296-90a5-ebbc54da2e85
52
+ ```
@@ -11,32 +11,35 @@ m365 spo list webhook list [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list to retrieve webhooks for 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 all webhooks for. Specify either `listId` or `listTitle` 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 all webhooks for. Specify either `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listTitle`, `listId` or `listUrl`.
21
21
 
22
- `--id [id]`
23
- : (deprecated. Use `listId` instead) ID of the list to retrieve all webhooks for. Specify either `id` or `title` but not both
24
-
25
- `--title [title]`
26
- : (deprecated. Use `listTitle` instead) Title of the list to retrieve all webhooks for. Specify either `id` or `title` but not both
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`.
27
24
 
28
25
  --8<-- "docs/cmd/_global.md"
29
26
 
30
27
  ## Examples
31
28
 
32
- List all webhooks for a list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/project-x_
29
+ List all webhooks for a list with a specific ID in a specific site
33
30
 
34
31
  ```sh
35
32
  m365 spo list webhook list --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf
36
33
  ```
37
34
 
38
- List all webhooks for a list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/project-x_
35
+ List all webhooks for a list with a specific title in a specific site
39
36
 
40
37
  ```sh
41
38
  m365 spo list webhook list --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle Documents
42
39
  ```
40
+
41
+ List all webhooks for a list with a specific URL in a specific site
42
+
43
+ ```sh
44
+ m365 spo list webhook list --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl '/sites/project-x/Documents'
45
+ ```
@@ -11,19 +11,22 @@ m365 spo list webhook remove [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list to remove the webhook from is located
14
+ : URL of the site where the list is located.
15
15
 
16
16
  `-l, --listId [listId]`
17
- : ID of the list from which the webhook should be removed. Specify either `listId` or `listTitle` but not both
17
+ : ID of the list. Specify either `listId`, `listTitle` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list from which the webhook should be removed. Specify either `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listId`, `listTitle` or `listUrl`.
21
+
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listId`, `listTitle` or `listUrl`.
21
24
 
22
25
  `-i, --id <id>`
23
- : ID of the webhook to remove
26
+ : ID of the webhook.
24
27
 
25
28
  `--confirm`
26
- : Don't prompt for confirming removing the webhook
29
+ : Don't prompt for confirmation.
27
30
 
28
31
  --8<-- "docs/cmd/_global.md"
29
32
 
@@ -33,20 +36,19 @@ If the specified id doesn't refer to an existing webhook, you will get a `404 -
33
36
 
34
37
  ## Examples
35
38
 
36
- Remove webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e81_ from a list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/ninja_
39
+ Remove webhook with a specific ID from a list retrieved by ID in a specific site
37
40
 
38
41
  ```sh
39
42
  m365 spo list webhook remove --webUrl https://contoso.sharepoint.com/sites/ninja --listId 0cd891ef-afce-4e55-b836-fce03286cccf --id cc27a922-8224-4296-90a5-ebbc54da2e81
40
43
  ```
41
44
 
42
- Remove webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e81_ from a list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/ninja_
43
-
45
+ Remove webhook with a specific ID from a list retrieved by Title in a specific site
44
46
  ```sh
45
47
  m365 spo list webhook remove --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --id cc27a922-8224-4296-90a5-ebbc54da2e81
46
48
  ```
47
49
 
48
- Remove webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e81_ from a list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/ninja_ without being asked for confirmation
50
+ Remove webhook with a specific ID from a list retrieved by URL in a specific site without being asked for confirmation
49
51
 
50
52
  ```sh
51
- m365 spo list webhook remove --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --id cc27a922-8224-4296-90a5-ebbc54da2e81 --confirm
53
+ m365 spo list webhook remove --webUrl https://contoso.sharepoint.com/sites/ninja --listUrl '/sites/ninja/Documents' --id cc27a922-8224-4296-90a5-ebbc54da2e81 --confirm
52
54
  ```
@@ -11,22 +11,28 @@ m365 spo list webhook set [options]
11
11
  ## Options
12
12
 
13
13
  `-u, --webUrl <webUrl>`
14
- : URL of the site where the list which contains the webhook is located
14
+ : URL of the site where the list is located.
15
15
 
16
16
  `-l, --listId [listId]`
17
- : ID of the list which contains the webhook which should be updated. Specify either `listId` or `listTitle` but not both
17
+ : ID of the list. Specify either `listId`, `listTitle` or `listUrl`.
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list which contains the webhook which should be updated. Specify either `listId` or `listTitle` but not both
20
+ : Title of the list. Specify either `listId`, `listTitle` or `listUrl`.
21
21
 
22
- `-i, --id [id]`
23
- : ID of the webhook to update
22
+ `--listUrl [listUrl]`
23
+ : Server- or site-relative URL of the list. Specify either `listId`, `listTitle` or `listUrl`.
24
+
25
+ `-i, --id <id>`
26
+ : ID of the webhook to update.
24
27
 
25
28
  `-n, --notificationUrl [notificationUrl]`
26
- : The new notification url
29
+ : The new notification url.
27
30
 
28
31
  `-e, --expirationDateTime [expirationDateTime]`
29
- : The new expiration date
32
+ : The new expiration date. _Note: Expiration Time cannot be more than 6 months in future_
33
+
34
+ `-c, --clientState [clientState]`
35
+ : A client state information that will be passed through notifications.
30
36
 
31
37
  --8<-- "docs/cmd/_global.md"
32
38
 
@@ -36,21 +42,24 @@ If the specified `id` doesn't refer to an existing webhook, you will get a `404
36
42
 
37
43
  ## Examples
38
44
 
39
- Update the notification url of a webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e81_ which belongs to a list with ID _0cd891ef-afce-4e55-b836-fce03286cccf_ located in site _https://contoso.sharepoint.com/sites/ninja_ to _https://contoso-functions.azurewebsites.net/webhook_
45
+ Update the notification url of a webhook with a specific ID attached to a list with a specific ID in a specific site to a specific URL
40
46
 
41
47
  ```sh
42
48
  m365 spo list webhook set --webUrl https://contoso.sharepoint.com/sites/ninja --listId 0cd891ef-afce-4e55-b836-fce03286cccf --id cc27a922-8224-4296-90a5-ebbc54da2e81 --notificationUrl https://contoso-functions.azurewebsites.net/webhook
43
49
  ```
44
50
 
45
- Update the expiration date of a webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e81_ which belongs to a list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/ninja_ to _October 9th, 2018 at 6:15 PM_
51
+ Update the expiration date of a webhook with a specific ID attached to a list with a specific title in a specific site to a specfic date
46
52
 
47
53
  ```sh
48
54
  m365 spo list webhook set --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --id cc27a922-8224-4296-90a5-ebbc54da2e81 --expirationDateTime 2018-10-09T18:15
49
55
  ```
50
56
 
51
- From the webhook with ID _cc27a922-8224-4296-90a5-ebbc54da2e81_ which belongs to a list with title _Documents_ located in site _https://contoso.sharepoint.com/sites/ninja_ update the notification url to _https://contoso-functions.azurewebsites.net/webhook_
52
- and the expiration date to _March 2nd, 2019_
57
+ Update the notification url and clientState of a webhook with a specific ID attached to a list with a specific URL in a specific site to a specific URL and the expiration date to a specific date
53
58
 
54
59
  ```sh
55
- m365 spo list webhook set --webUrl https://contoso.sharepoint.com/sites/ninja --listTitle Documents --id cc27a922-8224-4296-90a5-ebbc54da2e81 --notificationUrl https://contoso-functions.azurewebsites.net/webhook --expirationDateTime 2019-03-02
60
+ m365 spo list webhook set --webUrl https://contoso.sharepoint.com/sites/ninja --listUrl '/sites/ninja/Documents' --id cc27a922-8224-4296-90a5-ebbc54da2e81 --notificationUrl https://contoso-functions.azurewebsites.net/webhook --expirationDateTime 2019-03-02 --clientState 'My client state'
56
61
  ```
62
+
63
+ ## Respone
64
+
65
+ The command won't return a response on success.
@@ -14,10 +14,13 @@ m365 spo listitem add [options]
14
14
  : URL of the site where the item should be added
15
15
 
16
16
  `-l, --listId [listId]`
17
- : ID of the list where the item should be added. Specify `listId` or `listTitle` but not both
17
+ : ID of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : Title of the list where the item should be added. Specify `listId` or `listTitle` but not both
20
+ : Title of the list where the item should be added. 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, --contentType [contentType]`
23
26
  : The name or the ID of the content type to associate with the new item
@@ -64,3 +67,9 @@ Add an item with Title _Demo Hyperlink Field_ and a hyperlink field named _Custo
64
67
  ```sh
65
68
  m365 spo listitem add --listTitle "Demo List" --webUrl https://contoso.sharepoint.com/sites/project-x --Title "Demo Hyperlink Field" --CustomHyperlink "https://www.bing.com, Bing"
66
69
  ```
70
+
71
+ Add an item with a specific title to a list retrieved by server-relative URL in a specific site
72
+
73
+ ```sh
74
+ m365 spo listitem add --contentType Item --listUrl /sites/project-x/Documents --webUrl https://contoso.sharepoint.com/sites/project-x --Title "Demo Item"
75
+ ```
@@ -14,10 +14,13 @@ m365 spo listitem attachment list [options]
14
14
  URL of the site from which the item should be retrieved
15
15
 
16
16
  `--listId [listId]`
17
- : ID of the list from which to retrieve the item. Specify listId or listTitle but not both
17
+ : ID of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
18
18
 
19
19
  `--listTitle [listTitle]`
20
- : Title of the list from which to retrieve the item. Specify listId or listTitle but not both
20
+ : Title of the list where the item should be added. 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
  `--itemId <itemId>`
23
26
  ID of the list item to in question
@@ -37,3 +40,9 @@ Gets the attachments from list item with itemId _147_ in list with id _0cd891ef-
37
40
  ```sh
38
41
  m365 spo listitem attachment list --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf --itemId 147
39
42
  ```
43
+
44
+ Gets the attachments from a specific list item in a specific list obtained by server-relative URL in a specific site
45
+
46
+ ```sh
47
+ m365 spo listitem attachment list --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl /sites/project-x/Documents --itemId 147
48
+ ```
@@ -17,10 +17,13 @@ m365 spo listitem get [options]
17
17
  : ID of the item to retrieve.
18
18
 
19
19
  `-l, --listId [listId]`
20
- : ID of the list from which to retrieve the item. Specify `listId` or `listTitle` but not both
20
+ : ID of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
21
21
 
22
22
  `-t, --listTitle [listTitle]`
23
- : Title of the list from which to retrieve the item. Specify `listId` or `listTitle` but not both
23
+ : Title of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
24
+
25
+ `--listUrl [listUrl]`
26
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`
24
27
 
25
28
  `-p, --properties [properties]`
26
29
  : Comma-separated list of properties to retrieve. Will retrieve all properties if not specified and json output is requested
@@ -50,3 +53,9 @@ Get an items _Title_, _Created_ column and lookup column _Company_ with ID _147_
50
53
  ```sh
51
54
  m365 spo listitem get --listTitle "Demo List" --id 147 --webUrl https://contoso.sharepoint.com/sites/project-x --properties "Title,Created,Company/Title"
52
55
  ```
56
+
57
+ Get an item with specific properties from a list retrieved by server-relative URL in a specific site
58
+
59
+ ```sh
60
+ m365 spo listitem get --listUrl /sites/project-x/documents --id 147 --webUrl https://contoso.sharepoint.com/sites/project-x --properties "Title,Created,Company/Title"
61
+ ```
@@ -17,10 +17,13 @@ m365 spo listitem isrecord [options]
17
17
  : The ID of the list item to check if it is a record
18
18
 
19
19
  `-l, --listId [listId]`
20
- : The ID of the list where the item is located. Specify `listId` or `listTitle` but not both
20
+ : ID of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
21
21
 
22
22
  `-t, --listTitle [listTitle]`
23
- : The title of the list where the item is located. Specify `listId` or `listTitle` but not both
23
+ : Title of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
24
+
25
+ `--listUrl [listUrl]`
26
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`
24
27
 
25
28
  --8<-- "docs/cmd/_global.md"
26
29
 
@@ -37,3 +40,10 @@ Check whether the document with id _1_ in list with id _0cd891ef-afce-4e55-b836-
37
40
  ```sh
38
41
  m365 spo listitem isrecord --webUrl https://contoso.sharepoint.com/sites/project-x --listId 0cd891ef-afce-4e55-b836-fce03286cccf --id 1
39
42
  ```
43
+
44
+ Check whether a document with a specific id in a list retrieved by server-relative URL in a specific site is a record
45
+
46
+ ```sh
47
+ m365 spo listitem isrecord --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl /sites/project-x/documents --id 1
48
+ ```
49
+
@@ -16,8 +16,11 @@ m365 spo listitem list [options]
16
16
  `-i, --listId [listId]`
17
17
  : ID of the list to retrieve items from. Specify `listId` or `listTitle` but not both
18
18
 
19
+ `-l, --listId [listId]`
20
+ : ID of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
21
+
19
22
  `-t, --listTitle [listTitle]`
20
- : Title of the list to retrieve items from. Specify `listId` or `listTitle` but not both
23
+ : Title of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
21
24
 
22
25
  `-q, --camlQuery [camlQuery]`
23
26
  : CAML query to use to query the list of items with
@@ -85,3 +88,9 @@ From a list named _Demo List_ get the second batch of 10 items
85
88
  ```sh
86
89
  m365 spo listitem list --listTitle "Demo List" --webUrl https://contoso.sharepoint.com/sites/project-x --pageSize 10 --pageNumber 2
87
90
  ```
91
+
92
+ Get all items from a list by server-relative URL
93
+
94
+ ```sh
95
+ m365 spo listitem list --listUrl /sites/project-x/documents --webUrl https://contoso.sharepoint.com/sites/project-x
96
+ ```
@@ -14,10 +14,13 @@ m365 spo listitem record declare [options]
14
14
  : URL of the site where the list is located
15
15
 
16
16
  `-l, --listId [listId]`
17
- : The ID of the list where the item is located. Specify `listId` or `listTitle` but not both
17
+ : The ID of the list where the item is located. Specify either `listTitle`, `listId` or `listUrl`
18
18
 
19
19
  `-t, --listTitle [listTitle]`
20
- : The title of the list where the item is located. Specify `listId` or `listTitle` but not both
20
+ : The title of the list where the item is located. 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, --listItemId <listItemId>`
23
26
  : The ID of the list item to declare as record
@@ -47,8 +50,8 @@ Declare a document with id _1_ as a record with record declaration date _March 1
47
50
  m365 spo listitem record declare --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle "Demo List" --listItemId 1 --date 2012-03-14
48
51
  ```
49
52
 
50
- Declare a document with id _1_ as a record with record declaration date _September 3, 2013_ in list with id _ea8e1356-5910-abc9-bc05-2408198057fc_ located in site _https://contoso.sharepoint.com/sites/project-x_
53
+ Declare a document with a specific id as a record with a record declaration date a list retrieved by server-relative URL located in a specific site
51
54
 
52
55
  ```sh
53
- m365 spo listitem record declare --webUrl https://contoso.sharepoint.com/sites/project-x --listId ea8e1356-5910-abc9-bc05-2408198057fc --listItemId 1 --date 2013-09-03
56
+ m365 spo listitem record declare --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl '/sites/project-x/Lists/Demo List' --listItemId 1 --date 2013-09-03
54
57
  ```
@@ -17,10 +17,13 @@ m365 spo listitem record undeclare [options]
17
17
  : ID of the list item to be undeclared as a record.
18
18
 
19
19
  `-l, --listId [listId]`
20
- : The ID of the list where the item is located. Specify `listId` or `listTitle` but not both
20
+ : The ID of the list where the item is located. Specify either `listTitle`, `listId` or `listUrl`
21
21
 
22
22
  `-t, --listTitle [listTitle]`
23
- : The title of the list where the item is located. Specify `listId` or `listTitle` but not both
23
+ : The title of the list where the item is located. Specify either `listTitle`, `listId` or `listUrl`
24
+
25
+ `--listUrl [listUrl]`
26
+ : Server- or site-relative URL of the list where the item is located. Specify either `listTitle`, `listId` or `listUrl`
24
27
 
25
28
  --8<-- "docs/cmd/_global.md"
26
29
 
@@ -37,3 +40,9 @@ Undeclare the list item as a record with ID _1_ from list with title _List 1_ lo
37
40
  ```sh
38
41
  m365 spo listitem record undeclare --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'List 1' --listItemId 1
39
42
  ```
43
+
44
+ Undeclare a list item with a specific id as a record from a list retrieved by server-relative URL located in a specific site
45
+
46
+ ```sh
47
+ m365 spo listitem record undeclare --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl '/sites/project-x/Lists/Lists 1' --id 1
48
+ ```
@@ -17,10 +17,13 @@ m365 spo listitem remove [options]
17
17
  : The ID of the list item to remove.
18
18
 
19
19
  `-l, --listId [listId]`
20
- : List id of the list to remove. Specify either `listId` or `listTitle` but not both
20
+ : ID of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
21
21
 
22
22
  `-t, --listTitle [listTitle]`
23
- : Title of the list to remove. Specify either `listId` or `listTitle` but not both
23
+ : Title of the list where the item should be added. Specify either `listTitle`, `listId` or `listUrl`
24
+
25
+ `--listUrl [listUrl]`
26
+ : Server- or site-relative URL of the list. Specify either `listTitle`, `listId` or `listUrl`
24
27
 
25
28
  `--recycle`
26
29
  : Recycle the list item
@@ -43,3 +46,9 @@ Remove the list item with ID _1_ from list with title _List 1_ located in site _
43
46
  ```sh
44
47
  m365 spo listitem remove --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'List 1' --id 1
45
48
  ```
49
+
50
+ Remove the list item with a specific ID from a list retrieved by server-relative URL located in a specific site
51
+
52
+ ```sh
53
+ m365 spo listitem remove --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl /sites/project-x/lists/TestList --id 1
54
+ ```