Exchange Online Set Copy Items Send via Azure Runbook

This blog is about automating setting “Copy items sent” and “Copy items sent on behalf ” for Shared Mailboxes in Exchange Online. If Shared Mailboxes are created manually, It could be that these are settings are forgotten. If you forgot to set these settings it could have a high impact on users.

I am talking about these 2 settings:

The first thing you need to is create an Azure Automation Account. Go to “https://portal.azure.com/”, log in and search for Automation Account:

Click on Add, create a new resource group and choose the correct Geo location.

Then add a credential to the Automation Account. This must be an Exchange Online Administrator.

It’s time to add the Powershell script as a Runbook. Go to Runbooks and click on Create a runbook:

Pick a Name and choose powershell as Runbooktype:

After that you can add the script to the runbook. This is the code:

In addition, please fill in your automation credentials name you setup earlier.

After that you can go to schedules to plan the script every night.

If you have any questions about the runbook or want to schedule another script feel free to contact me.

Regards,

Niels

Related Posts

Leave a Reply