Right now I have a PS script that is checking for mailbox permissions and if they are missing, the permissions are added.
From C#, would like to call the equivalent of:
Get-MailboxPermission
and if needed, add permissions like:
Add-MailboxPermission -Identity $email -User $AdminUserName -AccessRights fullAccess -InheritanceType All
even if I can find the equivalent of Add-MailboxPermission that would do it. Cannot seem to find a REST equivalent or even a way with the GraphServiceClient.
I have looked at all of the available MS REST API references that I can find including Outlook, Graph, etc. to no avail. I can add the desired permissions via the web site and PS, but I am trying to keep this solution in C#