Map Google Meet transcript entries to call recording transcripts

Merged
EH
2d ago
+287-8

Context

Sixth PR of the Google Meet app, following #30587 (app shell), #30588 (test setup), #30589 (Google OAuth connection), #30590 (Meet API client) and #30591 (transcript, entry and participant listing). 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 pure functions that turn what the Meet API returns into what a Call Recording stores. Nothing calls them yet: the import in a following PR is their first user.

What this PR does

  • mapGoogleMeetTranscriptEntries: turns Meet transcript entries into the transcript shape the Teams and Fathom apps write to callRecording.transcript. Each entry gets the display name of its speaker and its offset in seconds from the start of the conference. Entries are ordered by start time, entries without text or start time are skipped, and a speaker missing from the participant list is kept with no name.
  • getGoogleMeetParticipantDisplayName: reads the name of a signed-in, anonymous or phone participant.
  • computeCallRecordingIdForGoogleMeetConference: derives a stable UUID v4 from the conference record name, so importing the same conference twice updates one Call Recording. Same derivation as the Teams and Fathom apps.

One Call Recording maps to one conference, not one transcript: Meet creates a new transcript each time transcription is restarted during a call, so the mapping accepts the entries of all of a conference's transcripts.

Also tightens three list tests from #30591 to assert the exact request (URL, headers, single call), following the Greptile review on that PR, which arrived after it was queued to merge.

Checks

Run locally in the app folder: yarn install --immutable, yarn lint, yarn typecheck, yarn test:unit (27 tests) and the repo formatter pass.