Milestone 0: import zappier billing, Verae middleware, and Zapier research

Compose-ready workspace: packages/zappier (rate card, portal, Stripe),
packages/verae-zapier-middleware (timestamp + NATS), packages/verae-zapier
(CLI app), vendor/zapier-platform, and research/zapier vendor corpus.

Gate 0 structure checks pass. Product code and research are not yet wired.
This commit is contained in:
George Lambert 2026-09-09 02:37:36 -04:00
commit b4150c8250
1364 changed files with 6814366 additions and 0 deletions

View file

@ -0,0 +1,58 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" width="1100" height="580"
viewBox="0 0 1100 580" role="img" aria-label="Middleware internals">
<title>Middleware internals</title>
<defs>
<marker id="arrow" viewBox="0 0 10 10" refX="9" refY="5"
markerWidth="7" markerHeight="7" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#1A6B6B"/>
</marker>
<marker id="arrow-navy" viewBox="0 0 10 10" refX="9" refY="5"
markerWidth="7" markerHeight="7" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#0F2744"/>
</marker>
<marker id="arrow-accent" viewBox="0 0 10 10" refX="9" refY="5"
markerWidth="7" markerHeight="7" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#C2410C"/>
</marker>
</defs>
<rect width="100%" height="100%" fill="#F8FAFC"/>
<text x="24" y="28" font-family="Helvetica, Arial, sans-serif" font-size="11" font-weight="700" fill="#1A6B6B" text-anchor="start">MIDDLEWARE INTERNALS</text>
<text x="24" y="50" font-family="Helvetica, Arial, sans-serif" font-size="20" font-weight="700" fill="#0F2744" text-anchor="start">verae-zapier-api/verae-zapier-middleware</text>
<rect x="20" y="80" width="160" height="70" rx="8" fill="#FFFFFF" fill-opacity="1" stroke="#0F2744" stroke-width="1.4"/>
<text x="100" y="110" font-family="Helvetica, Arial, sans-serif" font-size="12" font-weight="700" fill="#0F2744" text-anchor="middle">GET /health</text>
<text x="100" y="128" font-family="Helvetica, Arial, sans-serif" font-size="11" font-weight="400" fill="#334155" text-anchor="middle">liveness</text>
<rect x="200" y="80" width="880" height="70" rx="8" fill="#0F2744" fill-opacity="1" stroke="#0F2744" stroke-width="1.4"/>
<text x="640" y="110" font-family="Helvetica, Arial, sans-serif" font-size="16" font-weight="700" fill="#FFFFFF" text-anchor="middle">Express /zapier → /v1</text>
<text x="640" y="132" font-family="Helvetica, Arial, sans-serif" font-size="12" font-weight="400" fill="#CBD5E1" text-anchor="middle">authenticate · rateLimit on protected routes</text>
<rect x="20" y="172" width="340" height="180" rx="8" fill="#E8F1F8" fill-opacity="1" stroke="#C5D6E8" stroke-width="1.4"/>
<text x="36" y="198" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="700" fill="#1A6B6B" text-anchor="start">Public</text>
<text x="36" y="222" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">POST /v1/auth/login</text>
<text x="36" y="248" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">GET /v1/auth/me</text>
<text x="36" y="274" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">POST /v1/signup</text>
<text x="36" y="300" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">GET /v1/admin/* (X-Admin-Secret)</text>
<rect x="380" y="172" width="360" height="180" rx="8" fill="#FFFFFF" fill-opacity="1" stroke="#0F2744" stroke-width="1.8"/>
<text x="396" y="198" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="700" fill="#0F2744" text-anchor="start">Protected /v1</text>
<text x="396" y="222" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">/timestamp /timestamp/wait /batch</text>
<text x="396" y="248" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">/verify</text>
<text x="396" y="274" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">/status/:jobId[/verification]</text>
<text x="396" y="300" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">/webhooks/subscribe|unsubscribe</text>
<rect x="760" y="172" width="320" height="180" rx="8" fill="#F3EDE0" fill-opacity="1" stroke="#E0D2B4" stroke-width="1.4"/>
<text x="776" y="198" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="700" fill="#B45309" text-anchor="start">Services + store</text>
<text x="776" y="222" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">auth / entitlement / tenant</text>
<text x="776" y="248" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">timestamp / verify / webhook</text>
<text x="776" y="274" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">store.json tenants usage hooks</text>
<text x="776" y="300" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">veraeClient (+ mock)</text>
<rect x="20" y="372" width="520" height="180" rx="8" fill="#FFFFFF" fill-opacity="1" stroke="#0F2744" stroke-width="1.4"/>
<text x="36" y="400" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="700" fill="#0F2744" text-anchor="start">Flags</text>
<text x="36" y="426" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">NATS_ENABLED=false in-process job poller (Phase 6 product path)</text>
<text x="36" y="452" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">NATS_ENABLED=true JetStream workers; no in-process poller</text>
<text x="36" y="478" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">MOCK_VERAE=true deterministic jobs, no live Verae</text>
<text x="36" y="504" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">DEBUG_VERAE=auth,nats,jobs,webhooks,http,billing</text>
<rect x="560" y="372" width="520" height="180" rx="8" fill="#E8F6EE" fill-opacity="1" stroke="#B7DCC7" stroke-width="1.4"/>
<text x="576" y="400" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="700" fill="#15803D" text-anchor="start">Outbound</text>
<text x="576" y="426" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">HTTPS VERAE_API_BASE_URL (prod: api.veraetime.net)</text>
<text x="576" y="452" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">NATS NATS_URL nats://127.0.0.1:4222</text>
<text x="576" y="478" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">HTTPS Zapier targetUrl (webhook worker)</text>
<text x="576" y="504" font-family="Helvetica, Arial, sans-serif" font-size="13" font-weight="400" fill="#334155" text-anchor="start">Never bind NATS to a public interface</text>
</svg>

After

Width:  |  Height:  |  Size: 6.9 KiB