pnp/cli-microsoft365

Minimal permissions for 'spo list related' commands

Open

#7,481 opened on Aug 9, 2026

 (0 comments) (0 reactions) (0 assignees)TypeScript (399 forks)auto 404
docshelp wanted

Repository metrics

Stars
 (1,390 stars)
PR merge metrics
 (PR metrics pending)

Description

We're adding a new Permissions section to all commands. This section will document the minimal delegated and application permissions required to execute the command.

The goal is to:

  • Make it easier to run the CLI with custom app registrations and application permissions.
  • Ensure we only document the minimal set of permissions needed.
  • Keep documentation consistent by placing the Permissions section right before the Examples section.
  • If there are multiple resources, order them alphabetically
  • If there are commands that only support one type of auth (like delegated or app-only), we have an example for that as well. E.g. m365 planner tenant settings list - Permissions

Resources

Commands in scope

This issue covers the following commands:

  • m365 spo list contenttype add
  • m365 spo list contenttype list
  • m365 spo list contenttype remove
  • m365 spo list contenttype-default set
  • m365 spo list retentionlabel ensure
  • m365 spo list retentionlabel get
  • m365 spo list retentionlabel remove
  • m365 spo list roleassignment add
  • m365 spo list roleassignment remove
  • m365 spo list roleinheritance break
  • m365 spo list roleinheritance reset
  • m365 spo list sensitivitylabel ensure
  • m365 spo list sitescript get
  • m365 spo list view-field add
  • m365 spo list view-field remove
  • m365 spo list view-field set

Contributor guide