Skip to content

spo list retentionlabel remove

Clears the retention label on the specified list or library.

Usage

m365 spo list retentionlabel remove [options]

Options

-u, --webUrl <webUrl>
The URL of the site where the list is located.
-t, --listTitle [listTitle]
The title of the list on which to remove the label. Specify either listTitle, listId, or listUrl but not multiple.
-i, --listId [listId]
The ID of the list on which to remove the label. Specify either listTitle, listId, or listUrl but not multiple.
-l, --listUrl [listUrl]
Server- or web-relative URL of the list on which to remove the label. Specify either listTitle, listId, or listUrl but not multiple.
--confirm
Don'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, response, full. Default is full.
--query [query]
JMESPath query string. See http://jmespath.org/ for more information and examples
-o, --output [output]
Output type. json,text,csv,md. Default json
--verbose
Runs command with verbose logging
--debug
Runs command with debug logging

Examples

Clears the retention label on a given list by URL.

m365 spo list retentionlabel remove --webUrl https://contoso.sharepoint.com/sites/project-x --listUrl 'Shared Documents'

Clears the retention label on a given list by title.

m365 spo list retentionlabel remove --webUrl https://contoso.sharepoint.com/sites/project-x --listTitle 'Documents'

Clears the retention label on a given list by ID without confirmation.

m365 spo list retentionlabel remove --webUrl https://contoso.sharepoint.com/sites/project-x --listId 'Documents' --confirm

Response

The command won't return a response on success.