Replies: 2 comments
-
@whobday : you also need the Graph permissions for files/sites. The SharePoint permissions that you selected in Azure AD are only for SharePoint REST and SharePoint CSOM, the SharePoint Graph APIs require files and/or sites permission scopes (https://learn.microsoft.com/en-us/graph/api/driveitem-update?view=graph-rest-1.0&tabs=http). |
Beta Was this translation helpful? Give feedback.
-
Thanks for that link; unfortunately, adding those permissions didn't work. Here is the complete list of permissions for the App Registration(amended with the new permissions): I will pull down the repo and try to run the tests as detailed here. This page was the source of the recommended permissions I had initially applied. Edited to add: I'm having the same issue with renaming Libraries and Documents as well. |
Beta Was this translation helpful? Give feedback.
-
I'm attempting to use the Rename Folder method, but the Graph API is throwing a PnP.Core.MicrosoftGraphServiceException with a HTTPResponseCode of 403 - Access Denied.
Code:
From fiddler:
I'm using an Azure Application Registration for Access and have granted the following recommended permissions:
SharePoint -> Delegated Permissions -> AllSites -> AllSites.FullControl
SharePoint -> Delegated Permissions -> TermStore -> TermStore.ReadWrite.All
SharePoint -> Delegated Permissions -> User -> User.ReadWrite.All
SharePoint -> Application Permissions -> Sites -> Sites.FullControl.All
SharePoint -> Application Permissions -> TermStore -> TermStore.ReadWrite.All
SharePoint -> Application Permissions -> User -> User.ReadWrite.All
Microsoft Graph -> Delegated Permissions -> Group -> Group.ReadWrite.All
Microsoft Graph -> Delegated Permissions -> User -> User.Read
Microsoft Graph -> Delegated Permissions -> Directory -> Directory.ReadWrite.All
Microsoft Graph -> Application Permissions -> Group -> Group.ReadWrite.All
Microsoft Graph -> Application Permissions -> Directory -> Directory.ReadWrite.All
It's a permissions issue. I don't know what else to check.
P.S. MoveTo works just fine, and I will be using that until/if the Rename issue is resolved.
Beta Was this translation helpful? Give feedback.
All reactions