Skip to content

spo listitem roleinheritance break

Break inheritance of list item.

Usage

m365 spo listitem roleinheritance break [options]

Options

-u, --webUrl <webUrl>
URL of the site where the item for which to break role inheritance is located
--listItemId <listItemId>
ID of the item for which to break role inheritance
-l, --listId [listId]
ID of the list. Specify listId or listTitle but not both
-t, --listTitle [listTitle]
Title of the list. Specify listId or listTitle but not both
-c, --clearExistingPermissions
Set to clear existing roles from the list item
-h, --help
output usage information
--query [query]
JMESPath query string. See http://jmespath.org/ for more information and examples
-o, --output [output]
Output type. json,text,csv. Default json
--verbose
Runs command with verbose logging
--debug
Runs command with debug logging

Remarks

By default, when breaking permissions inheritance, the list item will retain existing permissions. To remove existing permissions, use the --clearExistingPermissions option.

Examples

Break inheritance of list item 1 in list someList located in site https://contoso.sharepoint.com/sites/project-x

m365 spo listitem roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listTitle "_someList_" --id 1

Break inheritance of list item 1 in list with ID 202b8199-b9de-43fd-9737-7f213f51c991 located in site https://contoso.sharepoint.com/sites/project-x

m365 spo listitem roleinheritance break --webUrl https://contoso.sharepoint.com/sites/project-x --listId 202b8199-b9de-43fd-9737-7f213f51c991 --id 1

Break inheritance of list item 1 in list someList located in site https://contoso.sharepoint.com/sites/project-x with clearing permissions

m365 spo listitem roleinheritance break --webUrl "https://contoso.sharepoint.com/sites/project-x" --listTitle "_someList_" --id 1 --clearExistingPermissions

Break inheritance of list item 1 in list with ID 202b8199-b9de-43fd-9737-7f213f51c991 located in site https://contoso.sharepoint.com/sites/project-x with clearing permissions

m365 spo listitem roleinheritance break --webUrl https://contoso.sharepoint.com/sites/project-x --listId 202b8199-b9de-43fd-9737-7f213f51c991 --id 1 --clearExistingPermissions