spo list defaultvalue get
Gets a specific default column value from a specific document library
Usage
m365 spo list defaultvalue get [options]
Options
-u, --webUrl <webUrl>URL of the site where the list is located.
-i, --listId [listId]ID of the list. Specify either
listTitle,listId, orlistUrl.-t, --listTitle [listTitle]Title of the list. Specify either
listTitle,listId, orlistUrl.--listUrl [listUrl]Server- or site-relative URL of the list. Specify either
listTitle,listId, orlistUrl.--fieldName <fieldName>Internal name of the field.
--folderUrl [folderUrl]Get a specific field of a specific folder by specifying a server- or site-relative URL.
-h, --help [help]Output usage information. Optionally, specify which section of command's help you want to see. Allowed values are
options,examples,remarks,permissions,response,full. Default isoptions.--query [query]JMESPath query string. See http://jmespath.org/ for more information and examples.
-o, --output [output]Output type.
json,text,csv,md,none. Defaultjson.--verboseRuns command with verbose logging.
--debugRuns command with debug logging.
Permissions
- Delegated
- Application
| Resource | Permissions |
|---|---|
| SharePoint | AllSites.Read |
| Resource | Permissions |
|---|---|
| SharePoint | Sites.Read.All |
Examples
Get default column value from the root folder of the list
m365 spo list defaultvalue get --webUrl https://contoso.sharepoint.com/sites/Marketing --listTitle Logos --fieldName Company
Get default column value from a specific folder of the list
m365 spo list defaultvalue get --webUrl https://contoso.sharepoint.com/sites/Marketing --listTitle Logos --fieldName Company --folderUrl "/sites/Marketing/Logos/Contoso"
Response
- JSON
- Text
- CSV
- Markdown
{
"fieldName": "Company",
"fieldValue": "Contoso",
"folderUrl": "sites/Marketing/Logos"
}
fieldName : Company
fieldValue: Contoso
folderUrl : sites/Marketing/Logos
fieldName,fieldValue,folderUrl
Company,Contoso,sites/Marketing/Logos
# spo list defaultvalue get --webUrl "https://contoso.sharepoint.com/sites/Marketing" --listTitle "Logos" --fieldName "Company"
Date: 2/20/2023
Property | Value
---------|-------
fieldName | Company
fieldValue | Contoso
folderUrl | sites/Marketing/Logos