Wiring
Runnpx vendo init --framework custom (detection lands here automatically
when the host is neither Next.js nor Express). It generates
vendo/server.ts: a lazy composition that takes Request in and returns
Response, with the environment passed per call.
Route your runtime’s requests through it:
<VendoRoot components={registry} theme={theme}> with <VendoOverlay /> in your SPA entry.
The three rules
- Construct lazily.
createVendo()performs no I/O and starts no timers at construction, but the generated lazy-singleton shape is still the contract: Workers forbids async work in module scope, and env vars only exist per request there. - Pass adapters explicitly. The dev credential ladder and the local
PGlite/Postgres store engines are Node-only and refuse with guidance on
edge runtimes. With
VENDO_API_KEYthe generated wiring fills every seam with the Cloud adapters — the model is the stock@ai-sdk/anthropicprovider pointed at the console gateway. Without a key, pass your ownmodel,store,connections, andsandbox. - Set
VENDO_BASE_URLto the deployed origin. Present-credential forwarding fails closed without it, andvendo doctorchecks it (E-AUTH-001).
What works where
vendo doctor judges unknown-framework hosts by their wiring
(E-WIRE-007/E-WIRE-008), never by another framework’s file layout.