Commit Graph

2 Commits

Author SHA1 Message Date
martbost 24b4ae9134 Hub gaps (Marty 2026-11-13): any later username/sponsor change (old members too) -> /v1/join, deliberate sponsor changes -> /v1/sponsor-change, MemberActivated -> /v1/contract-bind (contract iap); still one way, only with HUB_ENABLED
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-13 08:22:02 -06:00
martbost 5c896cb782 Network hub listener (hubsync.js), off unless HUB_ENABLED
POST /api/hub/events: signed hub hooks (HUB_SECRET, 5-minute window), each seq applied once, 503 so the hub retries.
member.joined from another door: /v1/resolve the person (climbing to sponsors not here yet) and make waiting accounts
through lsinbound.receive (joinedVia 'hub', joinedRef 'hub:<door>'); existing accounts keep their sponsor and the
difference is listed in /api/admin/hub. wallet.connected fills waiting accounts only; sponsor.changed is a TODO.
Our own new accounts and wallet links go to /v1/join and /v1/wallet from a persisted outbox (hubsync.json), never
in the way of a sign-up. With the flag off nothing is initialised, wired, routed or written; the LinkSpin sync is
unchanged. Test: qa/hubsync.test.cjs against a local network-hub (needs /v1/resolve by id, branch hub-resolve-id).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-12 17:02:45 -06:00