@pnp/cli-microsoft365 11.0.0-beta.4be9237 → 11.0.0-beta.88d51e6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.devproxy/api-specs/sharepoint.yaml +54 -0
- package/.eslintrc.cjs +2 -0
- package/allCommands.json +1 -1
- package/allCommandsFull.json +1 -1
- package/dist/m365/entra/commands/app/app-add.js +14 -2
- package/dist/m365/flow/commands/environment/environment-get.js +19 -29
- package/dist/m365/outlook/commands/mail/mail-searchfolder-add.js +85 -0
- package/dist/m365/outlook/commands.js +1 -0
- package/dist/m365/pa/commands/environment/environment-get.js +18 -23
- package/dist/m365/pp/commands/environment/environment-get.js +19 -26
- package/dist/m365/spo/commands/file/file-version-keep.js +78 -0
- package/dist/m365/spo/commands/list/list-view-add.js +1 -1
- package/dist/m365/spo/commands.js +1 -0
- package/dist/utils/entraApp.js +15 -0
- package/docs/docs/cmd/entra/app/app-add.mdx +7 -1
- package/docs/docs/cmd/flow/environment/environment-get.mdx +6 -5
- package/docs/docs/cmd/outlook/mail/mail-searchfolder-add.mdx +147 -0
- package/docs/docs/cmd/pa/environment/environment-get.mdx +5 -2
- package/docs/docs/cmd/pp/environment/environment-get.mdx +5 -2
- package/docs/docs/cmd/spo/file/file-version-keep.mdx +68 -0
- package/docs/docs/cmd/spo/list/list-view-add.mdx +11 -11
- package/package.json +1 -1
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
2
|
+
import Tabs from '@theme/Tabs';
|
|
3
|
+
import TabItem from '@theme/TabItem';
|
|
4
|
+
|
|
5
|
+
# outlook mail searchfolder add
|
|
6
|
+
|
|
7
|
+
Creates a new mail search folder in the user's mailbox
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
m365 outlook mail searchfolder add [options]
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Options
|
|
16
|
+
|
|
17
|
+
```md definition-list
|
|
18
|
+
`-i, --userId [userId]`
|
|
19
|
+
: The id of the user in whose mailbox the search folder should be created. Specify either `userId` or `userName`, but not both.
|
|
20
|
+
|
|
21
|
+
`-n, --userName [userName]`
|
|
22
|
+
: The UPN of the user in whose mailbox the search folder should be created. Specify either `userId` or `userName`, but not both.
|
|
23
|
+
|
|
24
|
+
`--folderName <folderName>`
|
|
25
|
+
: The name of the mail search folder.
|
|
26
|
+
|
|
27
|
+
`--sourceFolderIds <sourceFolderIds>`
|
|
28
|
+
: Comma-separated list of mail folders that should be searched.
|
|
29
|
+
|
|
30
|
+
`--includeNestedFolders`
|
|
31
|
+
: The nested mail folders will be searched if specified.
|
|
32
|
+
|
|
33
|
+
`--messageFilter <messageFilter>`
|
|
34
|
+
: The OData query to filter the messages.
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
<Global />
|
|
38
|
+
|
|
39
|
+
## Permissions
|
|
40
|
+
|
|
41
|
+
<Tabs>
|
|
42
|
+
<TabItem value="Delegated">
|
|
43
|
+
|
|
44
|
+
| Resource | Permissions |
|
|
45
|
+
|-----------------|----------------|
|
|
46
|
+
| Microsoft Graph | Mail.ReadWrite |
|
|
47
|
+
|
|
48
|
+
</TabItem>
|
|
49
|
+
<TabItem value="Application">
|
|
50
|
+
|
|
51
|
+
| Resource | Permissions |
|
|
52
|
+
|-----------------|----------------|
|
|
53
|
+
| Microsoft Graph | Mail.ReadWrite |
|
|
54
|
+
|
|
55
|
+
</TabItem>
|
|
56
|
+
</Tabs>
|
|
57
|
+
|
|
58
|
+
## Examples
|
|
59
|
+
|
|
60
|
+
Create a mail search folder in the user's mailbox specified by id for messages from the inbox that contain specific subject
|
|
61
|
+
|
|
62
|
+
```sh
|
|
63
|
+
m365 outlook mail searchfolder add --userId 1caf7dcd-7e83-4c3a-94f7-932a1299c844 --folderName 'CLI m365' --sourceFolderIds 'AQMkADYAAAIBDAAAAA==' --messageFilter "contains(subject, 'CLI for Microsoft 365')"
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Create a mail search folder in the user's mailbox specified by UPN for incoming and outgoing messages from a specific year that contain specific text in a message body, search for messages inside all subfolders
|
|
67
|
+
|
|
68
|
+
```sh
|
|
69
|
+
m365 outlook mail searchfolder add --userName john.doe@contoso.com --folderName 'Power Platform Community' --sourceFolderIds 'AQMkADYAAAIBDAAAAA==,AQMkADYAAAIBDBBBBB==' --includeNestedFolders --messageFilter "contains(body/content,'Power Platform') AND receivedDateTime ge 2024-01-01 AND receivedDateTime le 2024-12-31"
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
## Response
|
|
73
|
+
|
|
74
|
+
<Tabs>
|
|
75
|
+
<TabItem value="JSON">
|
|
76
|
+
|
|
77
|
+
```json
|
|
78
|
+
{
|
|
79
|
+
"id": "AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQABco84sgAAAA==",
|
|
80
|
+
"displayName": "Microsoft Entra",
|
|
81
|
+
"parentFolderId": "AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEEAAAA",
|
|
82
|
+
"childFolderCount": 0,
|
|
83
|
+
"unreadItemCount": 27,
|
|
84
|
+
"totalItemCount": 41,
|
|
85
|
+
"sizeInBytes": null,
|
|
86
|
+
"isHidden": false,
|
|
87
|
+
"isSupported": true,
|
|
88
|
+
"includeNestedFolders": false,
|
|
89
|
+
"sourceFolderIds": [
|
|
90
|
+
"AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEMAAAA"
|
|
91
|
+
],
|
|
92
|
+
"filterQuery": "contains(subject,'Microsoft Entra ID')"
|
|
93
|
+
}
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
</TabItem>
|
|
97
|
+
<TabItem value="Text">
|
|
98
|
+
|
|
99
|
+
```text
|
|
100
|
+
childFolderCount : 0
|
|
101
|
+
displayName : Microsoft Entra
|
|
102
|
+
filterQuery : contains(subject,'Microsoft Entra ID')
|
|
103
|
+
id : AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQABco88nAAAAA==
|
|
104
|
+
includeNestedFolders: false
|
|
105
|
+
isHidden : false
|
|
106
|
+
isSupported : true
|
|
107
|
+
parentFolderId : AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEEAAAA
|
|
108
|
+
sizeInBytes : null
|
|
109
|
+
sourceFolderIds : ["AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEMAAAA"]
|
|
110
|
+
totalItemCount : 41
|
|
111
|
+
unreadItemCount : 27
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
</TabItem>
|
|
115
|
+
<TabItem value="CSV">
|
|
116
|
+
|
|
117
|
+
```csv
|
|
118
|
+
id,displayName,parentFolderId,childFolderCount,unreadItemCount,totalItemCount,sizeInBytes,isHidden,isSupported,includeNestedFolders,filterQuery
|
|
119
|
+
AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQABco88ngAAAA==,Microsoft Entra,AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEEAAAA,0,27,41,,,1,,"contains(subject,'Microsoft Entra ID')"
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
</TabItem>
|
|
123
|
+
<TabItem value="Markdown">
|
|
124
|
+
|
|
125
|
+
```md
|
|
126
|
+
# outlook mail searchfolder add --debug "false" --verbose "false" --userName "john.doe@contoso.com" --folderName "Microsoft Entra4" --messageFilter "contains(subject,'Microsoft Entra ID')" --sourceFoldersIds "AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEMAAAA"
|
|
127
|
+
|
|
128
|
+
Date: 9/6/2024
|
|
129
|
+
|
|
130
|
+
## Microsoft Entra (AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQABco88oAAAAA==)
|
|
131
|
+
|
|
132
|
+
Property | Value
|
|
133
|
+
---------|-------
|
|
134
|
+
id | AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQABco88oAAAAA==
|
|
135
|
+
displayName | Microsoft Entra
|
|
136
|
+
parentFolderId | AQMkAGRlM2Y5YTkzLWI2NzAtNDczOS05YHqjbDnRgQAAAgEEAAAA
|
|
137
|
+
childFolderCount | 0
|
|
138
|
+
unreadItemCount | 27
|
|
139
|
+
totalItemCount | 41
|
|
140
|
+
isHidden | false
|
|
141
|
+
isSupported | true
|
|
142
|
+
includeNestedFolders | false
|
|
143
|
+
filterQuery | contains(subject,'Microsoft Entra ID')
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
</TabItem>
|
|
147
|
+
</Tabs>
|
|
@@ -16,7 +16,10 @@ m365 pa environment get [options]
|
|
|
16
16
|
|
|
17
17
|
```md definition-list
|
|
18
18
|
`-n, --name [name]`
|
|
19
|
-
: The name of the environment. When not specified, the default environment is retrieved.
|
|
19
|
+
: The name of the environment. When not specified, the default environment is retrieved. Specify either `name` or `default`, but not both.
|
|
20
|
+
|
|
21
|
+
`--default`
|
|
22
|
+
: Indicates that the default environment should be retrieved. Specify either `name` or `default`, but not both.
|
|
20
23
|
```
|
|
21
24
|
|
|
22
25
|
<Global />
|
|
@@ -36,7 +39,7 @@ If the environment with the name you specified doesn't exist, you will get the `
|
|
|
36
39
|
Get information about the default Power Apps environment.
|
|
37
40
|
|
|
38
41
|
```sh
|
|
39
|
-
m365 pa environment get
|
|
42
|
+
m365 pa environment get --default
|
|
40
43
|
```
|
|
41
44
|
|
|
42
45
|
Get information about the Power Apps environment with the specified name.
|
|
@@ -16,7 +16,10 @@ m365 pp environment get [options]
|
|
|
16
16
|
|
|
17
17
|
```md definition-list
|
|
18
18
|
`-n, --name [name]`
|
|
19
|
-
: The name of the environment. When not specified, the default environment is retrieved.
|
|
19
|
+
: The name of the environment. When not specified, the default environment is retrieved. Specify either `name` or `default`, but not both.
|
|
20
|
+
|
|
21
|
+
`--default`
|
|
22
|
+
: Indicates that the default environment should be retrieved. Specify either `name` or `default`, but not both.
|
|
20
23
|
|
|
21
24
|
`--asAdmin`
|
|
22
25
|
: Run the command as admin and retrieve details of environments you do not have explicitly assigned permissions to.
|
|
@@ -53,7 +56,7 @@ m365 pp environment get --name Default-d87a7535-dd31-4437-bfe1-95340acd55c5 --as
|
|
|
53
56
|
Get information about the default Power Platform environment.
|
|
54
57
|
|
|
55
58
|
```sh
|
|
56
|
-
m365 pp environment get
|
|
59
|
+
m365 pp environment get --default
|
|
57
60
|
```
|
|
58
61
|
|
|
59
62
|
## Response
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
2
|
+
import Tabs from '@theme/Tabs';
|
|
3
|
+
import TabItem from '@theme/TabItem';
|
|
4
|
+
|
|
5
|
+
# spo file version keep
|
|
6
|
+
|
|
7
|
+
Ensure that a specific file version will never expire
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
m365 spo file version keep [options]
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Options
|
|
16
|
+
|
|
17
|
+
```md definition-list
|
|
18
|
+
`-u, --webUrl <webUrl>`
|
|
19
|
+
: The URL of the site where the file is located.
|
|
20
|
+
|
|
21
|
+
`--fileUrl [fileUrl]`
|
|
22
|
+
: The server- or site-relative decoded URL. Specify either `fileUrl` or `fileId` but not both.
|
|
23
|
+
|
|
24
|
+
`-i, --fileId [fileId]`
|
|
25
|
+
: The UniqueId (GUID) of the file. Specify either `fileUrl` or `fileId` but not both.
|
|
26
|
+
|
|
27
|
+
`--label <label>`
|
|
28
|
+
: Label of the version.
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
<Global />
|
|
32
|
+
|
|
33
|
+
## Permissions
|
|
34
|
+
|
|
35
|
+
<Tabs>
|
|
36
|
+
<TabItem value="Delegated">
|
|
37
|
+
|
|
38
|
+
| Resource | Permissions |
|
|
39
|
+
|------------|----------------|
|
|
40
|
+
| SharePoint | AllSites.Write |
|
|
41
|
+
|
|
42
|
+
</TabItem>
|
|
43
|
+
<TabItem value="Application">
|
|
44
|
+
|
|
45
|
+
| Resource | Permissions |
|
|
46
|
+
|------------|---------------------|
|
|
47
|
+
| SharePoint | Sites.ReadWrite.All |
|
|
48
|
+
|
|
49
|
+
</TabItem>
|
|
50
|
+
</Tabs>
|
|
51
|
+
|
|
52
|
+
## Examples
|
|
53
|
+
|
|
54
|
+
Mark a file version as never expiring by file URL.
|
|
55
|
+
|
|
56
|
+
```sh
|
|
57
|
+
m365 spo file version keep --webUrl "https://contoso.sharepoint.com/sites/marketing" --fileUrl "/sites/marketing/Documents/report.docx" --label "6.0"
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Mark a file version as never expiring by file ID.
|
|
61
|
+
|
|
62
|
+
```sh
|
|
63
|
+
m365 spo file version keep --webUrl "https://contoso.sharepoint.com/sites/marketing" --fileId "12345678-90ab-cdef-1234-567890abcdef" --label "6.0"
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Response
|
|
67
|
+
|
|
68
|
+
The command won't return a response on success.
|
|
@@ -63,8 +63,8 @@ m365 spo list view add [options]
|
|
|
63
63
|
`--default`
|
|
64
64
|
: View will be set as default view, if specified.
|
|
65
65
|
|
|
66
|
-
`--paged`
|
|
67
|
-
: View supports paging
|
|
66
|
+
`--paged [paged]`
|
|
67
|
+
: View supports paging. Valid values are `true`, `false`. Defaults to `true`.
|
|
68
68
|
|
|
69
69
|
`--rowLimit [rowLimit]`
|
|
70
70
|
: Sets the number of items to display for the view. Default value is 30.
|
|
@@ -76,7 +76,7 @@ m365 spo list view add [options]
|
|
|
76
76
|
|
|
77
77
|
:::tip
|
|
78
78
|
|
|
79
|
-
We recommend using the `paged` option.
|
|
79
|
+
We recommend using the `paged` option. Paging is enabled by default: the view shows items page by page, up to the specified `rowLimit` per page. To disable paging, set `paged` to `false`; in a non-paged view, the `rowLimit` is absolute and there is no link to see more items.
|
|
80
80
|
|
|
81
81
|
:::
|
|
82
82
|
|
|
@@ -85,43 +85,43 @@ We recommend using the `paged` option. When specified, the view supports display
|
|
|
85
85
|
Add a list view called to a list with specific title.
|
|
86
86
|
|
|
87
87
|
```sh
|
|
88
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Customers" --title "All customers" --fields "LinkTitle,Country,Sector,Country,Address,Contact"
|
|
88
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Customers" --title "All customers" --fields "LinkTitle,Country,Sector,Country,Address,Contact"
|
|
89
89
|
```
|
|
90
90
|
|
|
91
91
|
Add a gallery view as default view to a list with a specific URL.
|
|
92
92
|
|
|
93
93
|
```sh
|
|
94
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listUrl "/Lists/Customers" --title "All customers" --type gallery --fields "LinkTitle,Country,Sector,Country,Address,Contact" --
|
|
94
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listUrl "/Lists/Customers" --title "All customers" --type gallery --fields "LinkTitle,Country,Sector,Country,Address,Contact" --default
|
|
95
95
|
```
|
|
96
96
|
|
|
97
97
|
Add a view with defined filter and sorting.
|
|
98
98
|
|
|
99
99
|
```sh
|
|
100
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Customers" --title "Transport customers" --fields "LinkTitle,Country,Country,Address,Contact" --viewQuery "<OrderBy><FieldRef Name='LinkTitle' Ascending='TRUE' /></OrderBy><Where><Eq><FieldRef Name='Sector' /><Value Type='Text'>Transportation</Value></Eq></Where>"
|
|
100
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Customers" --title "Transport customers" --fields "LinkTitle,Country,Country,Address,Contact" --viewQuery "<OrderBy><FieldRef Name='LinkTitle' Ascending='TRUE' /></OrderBy><Where><Eq><FieldRef Name='Sector' /><Value Type='Text'>Transportation</Value></Eq></Where>"
|
|
101
101
|
```
|
|
102
102
|
|
|
103
103
|
Add a gallery view as personal view.
|
|
104
104
|
|
|
105
105
|
```sh
|
|
106
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Customers" --title "All customers" --type gallery --fields "LinkTitle,Country,Sector,Country,Address,Contact" --
|
|
106
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Customers" --title "All customers" --type gallery --fields "LinkTitle,Country,Sector,Country,Address,Contact" --personal
|
|
107
107
|
```
|
|
108
108
|
|
|
109
109
|
Add a calendar view with month layout.
|
|
110
110
|
|
|
111
111
|
```sh
|
|
112
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Events" --title "All events" --type calendar --fields "EventType,InternalExternal" --calendarStartDateField EventStartDate --calendarEndDateField EventEndDate --calendarTitleField LinkTitle
|
|
112
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Events" --title "All events" --type calendar --fields "EventType,InternalExternal" --calendarStartDateField EventStartDate --calendarEndDateField EventEndDate --calendarTitleField LinkTitle
|
|
113
113
|
```
|
|
114
114
|
|
|
115
115
|
Add a calendar view with week layout and subtitle.
|
|
116
116
|
|
|
117
117
|
```sh
|
|
118
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Events" --title "All events" --type calendar --fields "EventType,InternalExternal" --calendarStartDateField EventStartDate --calendarEndDateField EventEndDate --calendarTitleField LinkTitle --calendarSubTitleField Location --calendarDefaultLayout week
|
|
118
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Events" --title "All events" --type calendar --fields "EventType,InternalExternal" --calendarStartDateField EventStartDate --calendarEndDateField EventEndDate --calendarTitleField LinkTitle --calendarSubTitleField Location --calendarDefaultLayout week
|
|
119
119
|
```
|
|
120
120
|
|
|
121
121
|
Add a Kanban board view.
|
|
122
122
|
|
|
123
123
|
```sh
|
|
124
|
-
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Tasks" --title "All tasks" --type kanban --fields "Title,AssignedTo" --kanbanBucketField Status
|
|
124
|
+
m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --listTitle "Tasks" --title "All tasks" --type kanban --fields "Title,AssignedTo" --kanbanBucketField Status
|
|
125
125
|
```
|
|
126
126
|
|
|
127
127
|
## Response
|
|
@@ -252,7 +252,7 @@ m365 spo list view add --webUrl https://contoso.sharepoint.com/sites/Sales --lis
|
|
|
252
252
|
<TabItem value="Markdown">
|
|
253
253
|
|
|
254
254
|
```md
|
|
255
|
-
# spo list view add --webUrl "https://contoso.sharepoint.com" --listTitle "Test" --title "All events" --fields "FieldName1" --viewQuery "<OrderBy><FieldRef Name='Created' Ascending='FALSE' /></OrderBy><Where><Eq><FieldRef Name='TextFieldName' /><Value Type='Text'>Field value</Value></Eq></Where>"
|
|
255
|
+
# spo list view add --webUrl "https://contoso.sharepoint.com" --listTitle "Test" --title "All events" --fields "FieldName1" --viewQuery "<OrderBy><FieldRef Name='Created' Ascending='FALSE' /></OrderBy><Where><Eq><FieldRef Name='TextFieldName' /><Value Type='Text'>Field value</Value></Eq></Where>"
|
|
256
256
|
|
|
257
257
|
Date: 2/20/2023
|
|
258
258
|
|
package/package.json
CHANGED