Inspiration
Small shops, event organisers, and clinics already put prices, dates, and prescriptions on paper—and their customers already have a phone and WhatsApp. Existing digital tools (e-commerce platforms, ticketing portals, and patient apps) fail this gap because they require accounts, logins, monthly fees, and desktop setup. Paperbone bridges paper and phone directly: snap a printed sheet, get a working mobile micro-app with no server, no account, and no install.
What it does
Paperbone is a lean, domain-agnostic skeleton (packages/core) powering three distinct mobile-first micro-apps. A customer scans a QR code or opens a link straight in their phone browser—and every live link works directly in a desktop browser too via image upload or the built-in sample buttons.
- SnapShop (Shelf photo or paper menu → Shareable storefront): Creates a storefront with WhatsApp ordering and an HMAC Price Lock that catches tampered prices line-by-line when an order is pasted back into the shop's verifier.
- SnapFlyer (Printed event flyer → Event page): Creates an event page with Add to Calendar (.ics), Open in Maps, and WhatsApp RSVP, preserving the event's local timezone.
- SnapDose (Printed prescription → Medication schedule): Creates a daily medication schedule with repeating calendar reminders—extracting strictly what is printed and deriving dose times from deterministic, tested rules without inventing medical advice.
Test it in 30 seconds (laptop- or phone-friendly): Open any of the three live links below (snapshop-studio.pages.dev, snapflyer-studio.pages.dev, or snapdose-studio.pages.dev), click a sample button or upload a photo, review or adjust items with Tap-to-Fix, and try the SnapShop Price Lock verifier or .ics calendar export end-to-end.
How we built it
- Zero-backend runtime: Static Cloudflare Pages apps powered by one shared, domain-agnostic core (packages/core). A stateless Cloudflare Worker calling Gemini handles capture-time OCR only; once created, all storefront, event, and schedule data lives inside the QR/URL itself so viewing, sharing, and verification work with no database and no server.
- Intentional UX for messy paper (Tap-to-Fix): Vision output is treated as an editable draft, never blind truth. Every app includes a fast Tap-to-Fix screen so users stay in control on curled, dense, or worn prints.
- The Skeleton Crew proof (2 + 1 with zero core edits): After shipping SnapShop and SnapFlyer, SnapDose was built from the exact same packages/core with zero changes to the core.
- Deterministic verification: Tested with Vitest, covering deterministic dose-schedule rules, HMAC price-lock verification, QR packet handling, and WhatsApp Status QR compression survivability.
How we used Kiro
- Kiro CLI (spec-first workflow): Built end-to-end with Kiro CLI in chat mode. Every app started from a spec in .kiro/specs/ before any code was written.
- Spec-driven development, not vibe coding: .kiro/specs/ holds core-engine, snapshop, snapflyer, and snapdose. The core-engine spec defines packages/core as strictly domain-agnostic, with no shop, event, or medicine knowledge inside it. Vibe coding would have let the core drift with each app; the spec held the boundary so SnapDose grew from the exact same core with zero edits.
- Scoped steering docs: .kiro/steering/ holds invariants.md, protocols.md, and vision-router.md. These files scope Kiro to the right files and rules for each task so a SnapFlyer change never touches SnapShop code and the vision router always uses the same Gemini cascade and Tap-to-Fix floor. invariants.md made the biggest difference: stating the core freeze and the zero-backend rule in one place meant every Kiro session enforced them without being reminded.
- Custom agent: .kiro/agents/app-builder.json builds a new app from the skeleton strictly against the core-engine spec so new verticals never edit packages/core.
- Agent hooks: .kiro/hooks/ automates two lifecycle gates:
- session-freeze-status.json runs at SessionStart and reports whether the repo is frozen, so work never starts on a frozen project by accident.
- stop-require-green-tests.json runs at Stop and blocks stopping unless the tests are green, so a session cannot end with a broken build.
- Custom Kiro Power: powers/paperbone-builder scaffolds a new paper-to-app vertical from the skeleton. It reads a spec, creates the app folder from _template, wires it to packages/core, and leaves the core untouched. SnapDose was scaffolded this way, proving a fourth app can be grown live from a single spec.
- Local MCP server: powers/paperbone-builder/mcp-server.mjs provides visual tools so Kiro can inspect and scaffold poster, printable Key Card, and QR rendering directly instead of guessing layouts from text—saving many manual rounds on WhatsApp Status QR sizing.
- Testing & invariants: Deterministic Vitest suites verify dose schedules, price-lock verification, and QR packet handling, and the core-engine spec also lists fast-check for property-based checks on core invariants.
Challenges we ran into
- Dense menus and curled receipts: Vision is not perfect on cluttered or folded paper. Instead of hiding misses behind cherry-picked inputs, we built Tap-to-Fix as a first-class screen in every app.
- WhatsApp Status compression: Aggressive image compression can break standard QR codes. We ran QR compression tests to lock in the size and error-correction level that survives real WhatsApp sharing.
- Keeping the skeleton genuinely lean: Keeping domain helpers out of packages/core across three very different verticals required mechanical guardrails via specs, steering, and hooks rather than willpower.
Accomplishments that we're proud of
- Three live, distinct apps from one unchanged core, proving the skeleton holds up past the two-app bar when SnapDose shipped with zero edits to packages/core.
- End-to-end real-phone validation: Scanning a printed storefront QR on a phone, placing a WhatsApp order, and catching a tampered price line-by-line with the HMAC Price Lock.
- Honest published evaluation: Keeping our vision evaluation published in the repo—even where dense, curled menus missed our target bar—and using those exact misses to design Tap-to-Fix.
What we learned
A skeleton is only real if a third app grows from it unchanged—SnapDose proved that boundary held. And a demo that shows a fast, honest human fix path is stronger than one that pretends vision never misses.
What's next for Paperbone
- Running a field pilot with 20 local shops and event organisers.
- Using powers/paperbone-builder to scaffold a fourth vertical live from a single spec.
- Expanding offline-first templates and direct payment/receipt handoffs for merchants.
Built With
- cloudflare-pages
- cloudflare-workers
- gemini
- javascript
- kiro
- typescript
- vitest