Write Google Meet conferences to call recordings
Context
Eighth PR of the Google Meet app, following #30587 (app shell), #30588 (test setup), #30589 (Google OAuth connection), #30590 (Meet API client), #30591 (transcript, entry and participant listing), #30592 (transcript mapping) and #30593 (calendar event matching). The app will import Google Meet recordings, transcripts and Gemini notes into Call Recordings, the same way the Teams, Fathom and Granola apps do. The full sequence of PRs is listed in #30587.
This one adds the step that writes a Call Recording, and gives the app role the access that step and the calendar matching need. Nothing calls it yet: the import in the next PR is its first user.
What this PR does
App role. The default role granted nothing until now. It now grants, and only grants:
- read on
calendarEvent, used by the calendar matching from #30593; - read, create and update on
callRecording.
No delete or destroy, no other object, no settings. It uses the recordsPermissions.objects shape; the older objectPermissions shape is deprecated in the SDK version the app pins.
Call Recording write.
buildGoogleMeetCallRecordingSyncFields: builds the fields of a Call Recording from a conference, its mapped transcript and its matched calendar event. The title comes from the calendar event because the Meet API gives a conference no title. The status isCOMPLETEDonce there is a transcript andPROCESSINGbefore.upsertCallRecordingOrThrow: creates the Call Recording under its deterministic id, or updates it when it exists. A recording a user deleted is left untouched instead of being recreated. When the create fails because another run created the same recording at the same moment, it updates that recording instead of failing. Same behaviour as the Teams app's upsert.
Checks
Run locally in the app folder: yarn install --immutable, yarn lint, yarn typecheck, yarn test:unit (50 tests), the repo formatter and twenty app build pass. The integration test needs a running server and was not run locally; CI runs it, which also installs the app with the new role.