-
Notifications
You must be signed in to change notification settings - Fork 358
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Get-PnPAvailableSensitivityLabel: Access denied. Check for the required permissions #2233
Comments
According to me, delegated Graph permissions of type I also noticed this command uses deprecated Graph endpoints. I made a PR to replace them with the new ones, but you'll still need the permissions listed above to make this work. |
Thanks @milanholemans for the comment, we will add this permission. |
Can you elaborate a little on which app needs to have the permissions? I'm not quite sure what Azure AD app is referring to here. I'm running into the same issue. |
In the back, all PnP apps (PnP PowerShell, M365 CLI, ...) use the same Azure AD app to authenticate to your tenant. Without this app, you don't have permission to query your tenant. You can find this app in Azure AD --> enterprise applications, there search for PnP Office 365 Management Shell. This app lacks the You can create your own app registration with your own permissions to work with PnP powershell. In this app registration you can grant the delegated |
@milanholemans , thanks for the response. I think I just got around to sorting that out when you responded. I appreciate the information. I agree that it would be easier if this were simply added to the app registration, though. |
Ok nice to hear it works for you now. I'm confident that this permission will be added to the PnP app registration. Much appreciated! 😊 |
Reporting an Issue or Missing Feature
Reporting a bug
Expected behavior
According to the documentation
Get-PnPAvailableSensitivityLabel
should give Microsoft Purview sensitivity labels in the currently connected tenantActual behavior
I am getting an error
Access denied. Check for the required permissions
whenever I try to runGet-PnPAvailableSensitivityLabel
Steps to reproduce behavior
What is the version of the Cmdlet module you are running?
Which operating system/environment are you running PnP PowerShell on?
The text was updated successfully, but these errors were encountered: