0016: Cloud is a product-agnostic relay
- Status: accepted
- Date: 2026-09-22
Context
A sibling product, sidedoor (a personal cross-device content board, a separate repo and product, to be restarted from scratch later), needs the same infrastructure vaultfold's hosted service provides: a zero-knowledge, end-to-end encrypted device relay, QR pairing with ephemeral ECDH and a human-verified short code, a persistent device trust graph, an append-only encrypted event log, and a blob store.
Decision
cloud/is built as a generic, versioned, documented, self-hostable device relay and immutable blob service. vaultfold is its first client.- Product-specific behaviour lives in clients, never in the relay.
- Billing data is architecturally separated from relay, channel and device data, so there is no join path between who paid and what was relayed, even under legal compulsion.
- Plan limits are enforced with macaroon-style capability tokens, so the relay enforces limits without knowing identity.
- One Polar account; products are plans, and bundles across products are possible.
Consequences
- The protocol must be versioned from the first release.
- vaultfold ships first and sidedoor waits on it.
- Cross-sell and bundle pricing become possible.
Alternatives considered
- Merging sidedoor into vaultfold. Rejected: different user, different promise; muddies the security story.
- Separate relays, one per product. Rejected: duplicate work and duplicate operations.