Share via

How to get permissions to sharepoint site

Mangesh Shinde 0 Reputation points
2025-05-20T09:40:40.6333333+00:00

I want to get permissions or members to added to SharePoint site by providing id.

Following is the API I am trying

https://graph.microsoft.com/v1.0/sites/siteID/permissions

but tried from ms graph explorer it is saying access denied what permission required form APP side.

I have admin concent for following permissions

Sites.Read.All Application level and delegate as well.

I want this implementation for Java SDK

Microsoft 365 and Office | SharePoint | Development
0 comments No comments

1 answer

Sort by: Most helpful
  1. 杨建宇 86 Reputation points MVP
    2026-03-15T10:42:40.6433333+00:00

    Yes, you can using graph api for this.

    1. you should have a service principle grant persmission first
    2. call graph api to get token
    3. using the token to call the specific api
    4. try to use powershell as below
    GET https://graph.microsoft.com/v1.0/sites/{site-id}/getByPath('/')/effectivePermissions/user({user-id})
    
    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.