Documentation for automated readers
A curated documentation index is available at: https://grafana.com/llms.txt
A complete documentation index is available at: https://grafana.com/llms-full.txt
These indexes can help with page discovery before fetching individual documents.
This page is also available in Markdown, which may be easier for automated readers and AI tools to parse than HTML. The Markdown version is available at https://grafana.com/docs/grafana-cloud/alerting-and-irm/irm/on-call-schedules/shift-swaps-overrides/automate-swaps.md, or by sending Accept: text/markdown to https://grafana.com/docs/grafana-cloud/alerting-and-irm/irm/on-call-schedules/shift-swaps-overrides/automate-swaps/. For broader documentation discovery, the curated index is available at https://grafana.com/llms.txt and the complete index is available at https://grafana.com/llms-full.txt.
Automate shift swap requests
Grafana IRM can automatically generate shift swap requests based on your Google Calendar Out of Office events. This integration helps ensure coverage for your on-call shifts when you’re unavailable, without manual intervention.
Before you begin
To set up automatic shift swap requests, you need:
- Access to Grafana IRM
SCHEDULES_WRITEpermission if RBAC is enabled- On-call schedules where you’re an assigned user
- A Google account with calendar access
Note
A Google account can only be linked to one Grafana Cloud instance at a time. To use the same account on a different instance, you must first disconnect it from the current instance.
How automatic shift swaps work
When you connect your Google Calendar to IRM:
- IRM periodically checks your calendar for Out of Office events
- If an Out of Office event overlaps with your on-call shifts, IRM automatically creates a shift swap request
- Team members can volunteer to cover these shifts
- If the Out of Office event changes, any related shift swap requests update to reflect the new times
IRM creates a shift swap request, it doesn’t automatically reassign the shift. The request appears in the Overrides section of the schedule timeline, and a teammate must volunteer to accept it before the coverage takes effect. To learn more about shift swap requests, refer to Manage shift swaps.
Connect your Google account
To link your Google Calendar with IRM:
- Navigate to the IRM tab of your Grafana user profile.
- Select the Google Calendar tab.
- Click Connect.
- Follow the on-screen prompts to authorize IRM to access your calendar.
- Select the on-call schedules to monitor for automatic shift swaps.
- By default, all schedules you participate in are selected.
- You can deselect any schedules you don’t want to include.
- Click Save to complete the setup.
Configure schedule selection
After connecting your Google account, you can modify which schedules are monitored for automatic shift swap requests:
- Navigate to the IRM tab of your Grafana user profile.
- Select the Google Calendar tab.
- Select or deselect schedules as needed.
- Click Save to apply your changes.
Manage Out of Office events
IRM responds to changes in your Google Calendar Out of Office events:
Create an Out of Office event
- In Google Calendar, create a new event.
- Mark the event as Out of office in the event type dropdown.
- Set the start and end times that cover your absence.
- Save the event.
IRM detects this event during its next sync cycle (typically within one hour) and creates shift swap requests for any overlapping shifts.
Update an existing Out of Office event
When you modify an Out of Office event in Google Calendar, IRM automatically updates any related shift swap requests to reflect the changes, including updates to the event duration and timing.
Delete an automated shift swap
If you delete a shift swap request that was automatically created from an Out of Office event, IRM doesn’t recreate it, even if the Out of Office event still exists.
Exclude specific events
To prevent an Out of Office event from generating a shift swap request:
- In Google Calendar, create or edit an Out of Office event.
- Add the tag
#grafana-irm-ignoreto the event title. - Save the event.
IRM ignores this event when generating shift swap requests, even if it overlaps with your on-call shifts.
If you add this tag to an existing Out of Office event that already has a shift swap request, IRM automatically deletes it.
Disconnect Google Calendar
If you need to disconnect your Google Calendar:
- Navigate to IRM > Users > View My Profile.
- Select the Google Calendar tab.
- Click Disconnect.
- Confirm your decision when prompted.
Disconnecting stops all automatic shift swap generation based on your calendar events.
Troubleshooting
If automatic shift swap requests aren’t being created:
- Verify your Google account is connected in your profile.
- Confirm the affected schedule is selected for monitoring.
- Check that your Out of Office events don’t contain the
#grafana-irm-ignoretag. - Ensure your Out of Office events are marked as Out of office in Google Calendar, not as regular events.
- Wait up to one hour for calendar sync.
- Check whether you have overlapping shifts during your Out of Office period.
- Check whether anyone has volunteered for your shift swap request.
Was this page helpful?
Related resources from Grafana Labs


