Table of Contents
Add Calendar Permissions in Office 365 via Powershell using Add-MailboxFolderPermission
Step by Step Guide for setting calendar permissions in Office 365:
First step would be launch Powershell as Administrator.
Second would be to open a new PS Session on powershell to Exchange Online/Office 365 using below commands.
$GetCred = Get-Credential
$PSSession = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $GetCred -Authentication Basic -AllowRedirection
Import-PSSession $PSSession
Now the last step is to configure the permissions for the user2 permissions on user1 calendar using below Powershell:
Add-MailboxFolderPermission -Identity [email protected]:\calendar -user [email protected] -AccessRights Editor
These are the available permissions levels for above -AccessRights are given below
- None: FolderVisible
- Owner: CreateItems, ReadItems, CreateSubfolders, FolderOwner, FolderContact, FolderVisible, EditOwnedItems, EditAllItems, DeleteOwnedItems, DeleteAllItems
- PublishingEditor: CreateItems, ReadItems, CreateSubfolders, FolderVisible, EditOwnedItems, EditAllItems, DeleteOwnedItems, DeleteAllItems
- Editor: CreateItems, ReadItems, FolderVisible, EditOwnedItems, EditAllItems, DeleteOwnedItems, DeleteAllItems
- PublishingAuthor: CreateItems, ReadItems, CreateSubfolders, FolderVisible, EditOwnedItems, DeleteOwnedItems
- Author: CreateItems, ReadItems, FolderVisible, EditOwnedItems, DeleteOwnedItems
- NonEditingAuthor: CreateItems, ReadItems, FolderVisible
- Reviewer: ReadItems, FolderVisible
- Contributor: CreateItems, FolderVisible
To check existing permissions, use below command
Get-MailboxFolderPermission -Identity [email protected]:\calendar
FolderName User AccessRights
———- —- ————
Calendar Default {AvailabilityOnly}
Calendar Anonymous {None}
Calendar user2 {AvailabilityOnly}
Calendar user4 {LimitedDetails}
If Existing permission already exists then use below command to change the permissions as needed.
Set-MailboxFolderPermission -Identity [email protected]:\calendar -user [email protected] -AccessRights Editor
To Check permissions again:
Get-MailboxFolderPermission -Identity [email protected]:\calendar
FolderName User AccessRights
———- —- ————
Calendar Default {AvailabilityOnly}
Calendar Anonymous {None}
Calendar user2 {Reviewer}
Calendar user4 {LimitedDetails}