Graph API (Java): Grant a (Team) Channel permissions to access a user file

Francisco Saez 0 Reputation points
2023-04-27T08:34:11.7066667+00:00

Hi,

how can I give permissions to a full (private) Channel from a Team to access any user file in Onedrive/Sharepoint.

I'm using the Java API with application access.

I've tried with these endpoints:

POST /shares/{encoded-sharing-url}/permission/grant

POST ..../items/{itemId}/invite

But they only let the recipient list to contain users or groups. So I can set permission for the whole Team but not for individual channels.

Any suggestion?

Thanks

Microsoft Teams
Microsoft Teams
A Microsoft customizable chat-based workspace.
10,312 questions
Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
12,273 questions
OneDrive
OneDrive
A Microsoft file hosting and synchronization service.
1,142 questions
Microsoft Teams Development
Microsoft Teams Development
Microsoft Teams: A Microsoft customizable chat-based workspace.Development: The process of researching, productizing, and refining new or existing technologies.
3,341 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Nivedipa-MSFT 3,031 Reputation points Microsoft Vendor
    2023-05-08T08:40:20.83+00:00

    @Francisco Saez - There doesn't seem to be any way available to give permissions to a Channel instead of users in channel.
    You can suggest this feature here: Microsoft Teams Community

    0 comments No comments

Your answer

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