Skip to content

Add Get, Grant, Set and Revoke cmdlets for EntraID app list item permissions#5294

Merged
KoenZomers merged 3 commits into
pnp:devfrom
fabianhutzli:feat/listitemsselected
Jun 5, 2026
Merged

Add Get, Grant, Set and Revoke cmdlets for EntraID app list item permissions#5294
KoenZomers merged 3 commits into
pnp:devfrom
fabianhutzli:feat/listitemsselected

Conversation

@fabianhutzli
Copy link
Copy Markdown
Contributor

Type

  • Bug Fix
  • New Feature
  • Sample

Summary

Adds four new cmdlets that manage app-only permissions on individual list items, enabling the use of the ListItems.SelectedOperations.Selected Entra ID app permission scoped to a single item.

New cmdlets

  • Get-PnPEntraIDAppListItemPermission – returns all or filtered item permissions (by PermissionId or AppIdentity)
  • Grant-PnPEntraIDAppListItemPermission – grants a new permission for an Entra ID app registration on a list item
  • Set-PnPEntraIDAppListItemPermission – updates the role of an existing list item permission
  • Revoke-PnPEntraIDAppListItemPermission – removes a list item permission (with confirmation prompt / -Force)

Implementation notes

  • Uses Microsoft Graph beta API (/sites/{siteId}/lists/{listId}/items/{itemId}/permissions)
  • The -ListItem parameter accepts the integer item ID (use Get-PnPListItem to resolve it)
  • Lists can be identified by GUID or display name
  • Permission roles are Read, Write, Owner
  • App display names are enriched via a best-effort GET /v1.0/servicePrincipals lookup
  • Documentation included
  • Developed with AI assistance
  • Tested

…issions

Implements ListItems.SelectedOperations.Selected support via the Microsoft
Graph beta API. The -ListItem parameter accepts the integer item ID only.
Lists can be addressed by GUID or display name. Permission roles use the
correct list-level values (Read, Write, Owner). Display names are enriched
via service principal lookup since the Graph beta API omits them on GET
responses. Documentation included.
@fabianhutzli fabianhutzli force-pushed the feat/listitemsselected branch from 0f6adeb to b0710ce Compare April 24, 2026 07:51
@KoenZomers
Copy link
Copy Markdown
Collaborator

Thanks for your contributions towards PnP PowerShell with this PR @fabianhutzli, much appreciated!

@KoenZomers
Copy link
Copy Markdown
Collaborator

@copilot resolve the merge conflicts in this pull request

@KoenZomers KoenZomers merged commit 78d7883 into pnp:dev Jun 5, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants