Add per-event Google Meet links to the calendar tools - #101
Merged
Conversation
`google_calendar_create_event` never sent `conferenceData`, so Google was never asked for a room and would not volunteer one — since September 2020 the API only attaches a conference when the caller explicitly requests it. Callers that needed a join link had no option but to reuse a standing room across every event, which Google warns against: shared conference data leaks meeting access between unrelated attendees. Both create and update now take `add_google_meet`. When set, the request carries a `conferenceData.createRequest` with a fresh UUID and the `conferenceDataVersion=1` query parameter — both are required, and Google silently drops the conference if either is missing. Conferences are minted asynchronously, so a response can come back `pending` with no `hangoutLink`. The event is re-read a few times until the link lands, since a conference nobody can join is the failure this is meant to prevent.
berges99
self-requested a review
July 26, 2026 09:34
berges99
approved these changes
Jul 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
google_calendar_create_eventnever sentconferenceData, so Google was never asked for a room and would not volunteer one. Since September 2020 the Calendar API only attaches a conference when the caller explicitly requests it — the user- and admin-level "automatically add video calls" settings do not apply to API-created events.That left callers who need a join link with one option: reuse a standing Meet room across every event. Google warns against exactly this:
It is also a practical problem: two meetings that overlap collide in the same room.
What
Both
google_calendar_create_eventandgoogle_calendar_update_eventtake a newadd_google_meet: bool(defaultFalse, so existing callers are unaffected).When set, the request carries a
conferenceData.createRequestwith a fresh UUIDrequestIdplus theconferenceDataVersion=1query parameter. Both are required and easy to get wrong independently — Google silently drops the conference if either is missing, and a reusedrequestIdreturns the conference it already made rather than a new one, which is how every event ends up sharing a room.Conferences are created asynchronously, so
events.insertcan answerpendingwith nohangoutLinkyet._await_conferencere-reads the event up to three times (0.5s, 1s, 2s) until the link lands, and stops immediately onsuccessorfailureso a calendar that cannot host Meet does not cost 3.5s.update_eventusesPATCH, so an ordinary reschedule withadd_google_meet=Falseleaves an existing conference untouched.Tests
python/tests/tools/test_google_calendar.py, 7 cases with httpx mocked: request ids are unique per call, the opt-in parameter and body travel together, the pending path polls and the failure path does not, and a plain update sends no conference data.