Make Granola sync credentials and discovery folders explicit
Merged
EH
12h ago+157+157+012345678901234567890123456789-58-58-01234567890123456789
Summary
Prepare the existing Granola sync for personal connections. This is the first change in the Granola personal sync rollout.
- Require an explicit API key in the Granola client and an explicit client in folder listing. The existing webhook uses the key it has already matched to its registration.
- Extract note discovery scheduling so callers pass the registration and folder scope explicitly. An empty discovery list queues zero jobs. Workspace sync passes an explicit workspace-wide scope for its existing Everything setting. The personal catch-up job will reuse this scheduler with its own registration and approved folders.
- Preserve workspace webhook routes, stored registrations, job IDs, and Call Recording IDs. This app-only refactor needs no migration or configuration change.
Verification
- Ran
yarn lint,yarn typecheck, andyarn test:unitin the Granola app. All 137 unit tests passed. - Built the Granola app with the Twenty CLI.
- Added regression coverage for a missing key with a workspace key configured, empty folder lists, and pacing across distinct folders.
- Deployed integration checks run in CI.