domainwidedelegation.comStart free

Use cases → Scheduling

Automatically reserve meeting rooms via service account

Book physical meeting rooms on users’ behalf using delegated access, ensuring resource calendars are updated instantly and consistently.

Who it is forIT automation teams handling room scheduling for growing organisations.
APIsCalendar API, Admin SDK
Typical scopescalendar, admin.directory.resource.calendar

The problem

Manual room booking is error-prone—double bookings get missed, and people forget to update or cancel reservations. Automating bookings through a service account avoids human error, but brings its own operational quirks.

How it works

  1. Use the Admin SDK to list available resource calendars and map them to room names.
  2. Impersonate the requesting user via domain-wide delegation.
  3. Insert the event into the user’s calendar and add the room resource as an attendee.
  4. Monitor the room calendar to confirm acceptance or handle conflicts.
  5. Notify users if the booking fails due to a conflict or policy restriction.

What changes

Room calendars reflect bookings in real time, and users receive clear confirmation or failure results, reducing scheduling confusion.

The trap in this one. If you insert the event directly into the resource calendar (impersonating the room), the booking appears but doesn't trigger email notifications or attendee status updates—users may believe the room is reserved when it isn’t. The correct pattern is to book as the user and invite the room as a resource attendee, letting Google’s internal logic enforce conflicts and send responses. Skipping this step leads to silent, invisible failures where the room shows as booked, but no one is actually notified or invited.

Watch it explained

“Google Apps Script Code a Calendar Reservation System - JavaScript Dates and Time” — Mr. Kaiser on YouTube. Third-party video, included because it covers this ground well. We are not affiliated with the channel.

Questions people ask

Can I just create events directly on the room calendar?

You can, but you’ll bypass Google’s conflict detection and notification system. Always book as the user and invite the room instead.

How do I handle recurring bookings?

Use the recurring event syntax in the Calendar API, but check each instance for room conflicts; Google may decline some but not all.

Want this built?

This is a pattern we run in production. We will set up the delegation and build this on top of it — $500 per hour, most of it working the same day.

Talk to us Or read the setup guide

Related use cases

Provision calendar events based on group membership

Create or update events for all members of a Google Group by impersonating users with a service account.

Cancel events across many calendars at once

Bulk-cancel meetings for multiple users after a team change, departure or incident, using domain-wide delegation.

Set up team-wide calendar blockers from a service account

Block calendar slots for entire teams using delegated automation, ensuring no one books over key periods or events.