Hossain Labs

Home / Blog / Exchange Online

Secure and Efficient Room Scheduling: Restricting Access with Set-CalendarProcessing

By Md Sajid Hossain29 April 2025Updated 1 December 20262 min read

A meeting room should accept requests from one group and handle everyone else differently. Read the current booking policy first, then test with a member and a nonmember.

Scenario: Ensuring Only Authorized Groups Can Book Rooms

Let's consider a scenario where you need to ensure that only members of a designated distribution list or a mail-enabled security group can successfully book a particular room mailbox.

Step-by-Step Configuration:

To configure the room mailbox to exclusively accept booking requests from the defined group, use the Set-CalendarProcessing cmdlet with the following parameters:

  • For a Distribution List: If you want to limit bookings to a specific distribution list, use this command:

    PowerShell
    Set-CalendarProcessing -Identity "RoomMailbox" -AutomateProcessing AutoAccept -BookInPolicy "DistributionList" -AllBookInPolicy $false

    Here, -BookInPolicy specifies the distribution list, and -AllBookInPolicy $false ensures that only members of this list are allowed to book automatically.

  • For a Mail-Enabled Security Group: To restrict bookings to a mail-enabled security group, execute this command:

    PowerShell
    Set-CalendarProcessing -Identity "RoomMailbox" -AutomateProcessing AutoAccept -BookInPolicy "MailEnabledSecurityGroup" -AllBookInPolicy $false

    Similar to the distribution list scenario, -BookInPolicy identifies the security group, and -AllBookInPolicy $false enforces the restriction.

Once these commands are executed, only individuals who are members of the specified distribution list or mail-enabled security group will be able to successfully book the "RoomMailbox". All booking attempts from users outside these groups will be automatically declined by the system.

Extending Functionality:

  • Customizing the Decline Message: You can provide a more informative message to users whose bookings are declined:

    PowerShell
    Set-CalendarProcessing -Identity "RoomMailbox" -AddAdditionalResponse $true -AdditionalResponse "Your room booking request was not approved as you are not a member of the authorized booking group."
  • Allowing Specific Users to Request Approval: In situations where certain users need to request bookings even if they are not part of the authorized group, you can designate them to require approval:

    PowerShell
    Set-CalendarProcessing -Identity "RoomMailbox" -RequestOutOfPolicy User1,User2 -ResourceDelegates "delegateuser"

    In this example, User1 and User2 can submit requests that will then need to be approved by the user(s) specified in -ResourceDelegates.

Conclusion:

Implementing booking restrictions on room mailboxes using the Set-CalendarProcessing cmdlet is a vital step in maintaining control over shared resources in Microsoft 365. By limiting access to specific groups and utilizing options for custom messages and approval workflows, organizations can ensure efficient and secure management of their meeting spaces.

References

Md Sajid Hossain

Modern Workplace & Data Security Engineer in Dhaka. Microsoft 365, Purview, Entra ID and Exchange, from real tenants and support cases.

Work with me · LinkedIn