spo list sensitivitylabel remove
Clears a default sensitivity label from a document library
Usage
m365 spo list sensitivitylabel remove [options]
Options
-u, --webUrl <webUrl>The URL of the site where the list is located.
-t, --listTitle [listTitle]The title of the library on which to remove the label. Specify either
listTitle,listId, orlistUrlbut not multiple.-l, --listId [listId]The ID of the library on which to remove the label. Specify either
listTitle,listId, orlistUrlbut not multiple.--listUrl [listUrl]Server- or web-relative URL of the library on which to remove the label. Specify either
listTitle,listId, orlistUrlbut not multiple.-f, --forceDon't prompt for confirmation.
-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.Write |
| Resource | Permissions |
|---|---|
| SharePoint | Sites.ReadWrite.All |
Examples
Removes a sensitivity label from a document library based on the list title.
m365 spo list sensitivitylabel remove --webUrl 'https://contoso.sharepoint.com' --listTitle 'Shared Documents'
Removes a sensitivity label from a document library based on the list url.
m365 spo list sensitivitylabel remove --webUrl 'https://contoso.sharepoint.com' --listUrl '/Shared Documents'
Removes a sensitivity label from a document library based on the list id without prompting for confirmation.
m365 spo list sensitivitylabel remove --webUrl 'https://contoso.sharepoint.com' --listId 'b4cfa0d9-b3d7-49ae-a0f0-f14ffdd005f7' --force
Response
The command won't return a response on success.