Office 365 – Removing shared permissions to a calendar via PowerShell

Problem: Client wanted to remove select users from a shared calendar Solution:(h/t IQinIT) $cred = Get-Credential $session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $cred -Authentication Basic –AllowRedirection Import-PSSession $session Get-MailboxFolderPermission -Identity user@domain.com:\Calendar| Select User, AccessRights, Deny Remove-MailboxFolderPermission -Identity user@domain.com:\Calendar -User user2@domain.com