QairoPay lets businesses issue loyalty, membership and stored-value passes to Apple Wallet and Google Wallet, and gives staff a scanner app to redeem them at the counter. It is a multi-tenant platform with a brand dashboard, scanner PWA, super-admin console, member app and developer portal, with an Aptos-based USDC settlement layer underneath. The repo is built with a Spec-Driven Development (Spec Kit) workflow governed by a 14-principle constitution.
The problem
Brands that run loyalty and membership programs want the card in the phone’s wallet, where members keep it. The pass-issuance tools the PRD surveyed stop at issuance. They won’t rotate a barcode more often than once a day, and they leave the counter, the scanner and payments to someone else.
The PRD names three users. Brand staff design and issue passes. Venue staff scan them at a gate or till, often on a weak network. Platform staff handle tenants, compliance and treasury. Each gets its own surface and permissions.
What we built
A brand signs in to its dashboard, designs a pass template, and issues passes one at a time, in batches, through a form, by link or over the API. Members add the pass to Apple Wallet or Google Wallet and get lock-screen updates when a stamp lands. At the counter, staff scan the QR or NFC pass in the scanner app and redeem. Developers get a portal with SDKs in TypeScript, Python, Go, Swift and Kotlin.
Underneath is a Fastify, Drizzle and Postgres API with Redis queues. Every state change writes to an append-only audit log, and sensitive fields use envelope encryption backed by Cloud KMS. One package signs Apple PassKit and Google Wallet passes; another signs NFC scan envelopes with Ed25519. Webhooks are HMAC-signed, SSRF-guarded and retried with backoff. Settlement runs through an Aptos Move module with sponsored transactions.
How we built it
The repo runs on Spec Kit. A constitution of 14 binding principles sits above everything, and each feature moves from spec to plan to tasks to code in its own folder under specs/. AGENTS.md gives every coding agent the same rules: architecture boundaries, a 400-line PR target, and paths (auth, payments, migrations, crypto, infrastructure) that need human approval before an agent touches them.
Agents wrote most of the code. 544 of the 813 commits on main carry a Claude co-author, and an Obvious Autobuild agent opened 192 PRs during a November build sprint. Agents work in their own sandboxes, but the only check that counts is our self-hosted Woodpecker CI. Every PR body must include the local CI run, plus phone and desktop screenshots for UI changes. Payments and pass issuance are test-first, integration tests run against real Postgres and Redis, and Playwright compares the UI against 374 committed baseline images.
A person merged 447 of the 618 merged PRs. The autobuild agent merged the other 171 during the sprint, under a rule that every merge carries a full local CI run.
What was hard
Keeping the wallet tap away from money. A wallet pass NFC tap applies loyalty and redemption only, never a payment. Spending goes through Pay by QR, an issued card or Tap to Pay. We enforce this in two places, the API’s payment path and the POS gateway, each with a test that rejects NFC-derived credentials.
Upgrading passes already in people’s wallets. Early passes carried a QR with the bare pass ID. The new code is signed with the tenant’s key. Moving installed passes over took a paced, resumable re-push to Apple and Google (120 passes a minute by default) that survives a deploy mid-run. Tenants can reject old codes only once every pass has been re-sent, and a counter shows how many old codes are still scanned.
Scanning when the Wi-Fi drops. Venue gates lose network. The scanner keeps a local pass cache, records offline scans as provisional, and replays them on reconnect. The server flags any pass that two devices redeemed while both were offline.
By the numbers
- 618 merged pull requests, 2 open
- 813 commits on main since May 12, 2026
- 35 feature spec folders
- 1,093 test files: 1,044 TypeScript/JavaScript, 18 Go, 16 Python, 15 Swift and Kotlin
- 374 committed visual-regression baseline images
- 6 apps and 20 shared packages in one workspace
Where it is now
The marketing site, developer portal and tenant dashboard are live. Pass issuance, wallet updates, scanning and loyalty run end to end. Every money path is pinned to testnet and devnet until the owner approves mainnet.
Recent work added a member list and a first-run setup wizard. Next, settlement becomes chain-agnostic: one interface in front of a double-entry ledger, with Aptos as the first rail and a Solana adapter already in the repo.



