This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Connect using your tenants SharePoint admin url. | |
Connect-PnPOnline -Url M365x28850929-admin.sharepoint.com -Interactive | |
#Enter the App ID you coped from the Enterprise Application. | |
$ManagedIdentityID = "4bf49741-7819-47f1-9e30-c36ef6b9d1aa" | |
Add-PnPAzureADServicePrincipalAppRole -Principal $ManagedIdentityID -AppRole "Sites.ReadWrite.All" -BuiltInType MicrosoftGraph | |
Add-PnPAzureADServicePrincipalAppRole -Principal $ManagedIdentityID -AppRole "Sites.FullControl.All" -BuiltInType MicrosoftGraph | |
Add-PnPAzureADServicePrincipalAppRole -Principal $ManagedIdentityID -AppRole "Sites.FullControl.All" -BuiltInType SharePointOnline |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment