feat: added HMAC sheet sync endpoint #2
No reviewers
Labels
No labels
needs/docs
needs/research
needs/upstream
type/bug
type/external
type/feature
type/refactor
urgency
high
urgency
immediate
urgency
low
urgency
medium
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ScottyLabs/nova-crowd-favorite!2
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/sheet-sync"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Adds the Sheet → SQLite sync. An Apps Script on the submission Sheet sends all rows to
POST /api/syncevery 2 minutes, signed with HMAC-SHA256 using a shared secret.Changes
src/lib/server/parse.ts: reads rows by header name; trims names, splits members and emails, lowercases emailssrc/lib/server/sync.ts: updates teams and members in one transaction; teams removed from the Sheet are marked inactive instead of deletedsrc/lib/server/hmac.ts: checks the signature overtimestamp.bodyand rejects requests older than 5 minutessrc/routes/api/sync/+server.ts: the endpoint; checks the signature before reading the datascripts/apps-script.gs: the script to add to the Sheet (setup steps in the file)scripts/send-test-sync.ts: local stand-in for the Apps Script, for testingsecretspec.toml: addsSYNC_HMAC_SECRETTested locally
active = 0, not deletedNeeds before merge
SYNC_HMAC_SECRETset in OpenBao for preview and prod (I only have dev set up locally). The preview deploy will fail until then.Kennel Deployments
Torn down at 2026-10-15 18:57:59 UTC.
WIP: feat: added HMAC sheet sync endpointto feat: added HMAC sheet sync endpoint