PartKit · demo
PartKit · demo

Join the waitlist.

A one-page micro-SaaS assembled from four verified parts — rate limiting, an append-only audit log, transactional email, and signed webhook ingestion. The app you're looking at wrote only the seams between them.

→ View the audit trailEvery signup & webhook delivery lands in an unrewritable log.
POST /api/joinratelimit.apiappend signup+email.transactionalaudit.logwebhooks.ingest

The seams, part by part

Pick a part. On the left is the entire seam this app wrote to wire it; on the right, the contract invariantthat seam leans on. That's the deal — the part guarantees the invariant, the app writes the seam, nothing in parts/ is touched.

ratelimit.apiproxy.ts
// proxy.ts — Next 16's renamed middleware (Node runtime)
const limiter = rateLimitMiddleware({
  rule: { limit: 5, windowSeconds: 60 },
});

export async function proxy(request: NextRequest) {
  const limited = await limiter(request);  // 429, or null to pass
  return limited ?? NextResponse.next();
}

export const config = { matcher: "/api/join" };

The middleware mount. The app picks the policy; the part enforces it.

contract invariant #1contract.json ↗
Within one fixed window, the first `limit` requests for a key are allowed and every request beyond `limit` is rejected
Guaranteed by ratelimit.api · verified by its conformance suite · attested in parts.lock.

Try to break it

The verification half — the parts' defenses, fired live against this running app. No build, no vendor, no credentials.

ratelimit.apiper-IP budget · 5 / 60s
5 / 5 remaining
click to spend the budget…
webhooks.ingestsignature · replay · tamper
expect 200
expect 400
expect 400

Each delivery is signed server-side with the real WEBHOOK_SECRET, then sent to the mounted route. The part verifies the HMAC over the raw bytes before the handler runs.

Flip the vendor in one command

Switching Resend → Postmark is a partkit upgrade, not a rewrite. The vendored adapter and the env line change; not one seam line moves. Captured from a real run:

$ partkit upgrade email.transactional --adapter=postmark
email.transactional 1.0.1 → 1.0.1 · adapter resend → postmark
  • parts/email.transactional/adapters/selected/adapter.ts48
  • parts/email.transactional/ATTESTATION.json10
  • parts.lock"adapter": "resend" → "postmark"
  • .env.exampleEMAIL_ADAPTER=resend → postmark
seam files changed: 0— the app never knows which vendor it's on.

Proof: only the seams

17
seam files authored
(+2105 lines)
0
lines hand-written
under parts/
61
vendored part files
(3,850 lines)
partkit guard
boundary intact
app/globals.css+793
app/page.tsx+169
app/_components/BreakIt.tsx+165
app/trail/page.tsx+135
lib/exhibits.ts+128
scripts/send-test-webhook.mjs+108
app/_components/JoinForm.tsx+96
app/api/demo/route.ts+94
scripts/gen-proof.mjs+89
app/api/join/route.ts+64
app/_components/SeamExplorer.tsx+61
lib/email/welcome.ts+51
app/layout.tsx+48
app/api/webhooks/ingest/route.ts+46
lib/db.ts+31
proxy.ts+27

Attested bill of materials

Rendered live from parts.lock — every part pinned by content hash, with its conformance attestation.

partveradapterattestationexpires
audit.log1.0.1dev:unsigned2026-06-25
email.transactional1.0.1resenddev:unsigned2026-06-25
ratelimit.api1.0.1dev:unsigned2026-06-25
webhooks.ingest1.0.1standardwebhooksdev:unsigned2026-06-25

Vendored from registry.partkit.dev via the published CLI (no --registry flag). dev:unsigned = local dev attestation; production re-issues signed ones in CI. partkit.dev →