A Crowdfunding Platform for Petty Grievances, Built on a Payout State Machine
A viral fundraising app where people create jars for petty grievances, the community chips in, and service providers complete counter-acts for proof and payout.
PettyJar is crowdfunding pointed at the small stuff. Someone parks in your spot or cuts in line, you create a "jar" describing the petty grievance, other people chip in small amounts to fund a counter-act, the community votes on what the counter-act should be, and a service provider completes it and submits proof. Everyone gets to watch harmless justice served. It is a silly premise sitting on top of some genuinely non-trivial plumbing.
The real problem is moving money safely
The fun part is the concept. The hard part is that PettyJar is a two-sided marketplace that moves real money, and that raises the engineering bar considerably. Payments run through Stripe, using Checkout for jar creation and chip-ins and Stripe Connect for paying out to service providers. Between the money coming in and the money going out sits an automated payout state machine, which is the piece I care most about. Funds should only be released once a counter-act is actually completed and proven, so the lifecycle from funded, to claimed, to proven, to paid has to be modeled explicitly rather than hand-waved. A marketplace that gets that state machine wrong either pays for work that never happened or strands money that was owed.
Anonymous but accountable
Users are anonymous, authenticated through JWT tokens rather than accounts tied to identity, which fits the playful and slightly mischievous spirit of the thing. Keeping it anonymous while still supporting payments, voting, and a provider marketplace is a real constraint, and it shaped the auth design. On top of that sits admin moderation, because anything viral and grievance-shaped needs a brake.
Built for real time and virality
The stack is chosen for liveness. The frontend is React 18 with Vite, TypeScript, and Tailwind, backed by Supabase for real-time features. The backend is Express with TypeScript, Prisma over PostgreSQL in production and SQLite in development, and it pushes live updates through Server-Sent Events with Redis pub/sub. A viral scoring algorithm surfaces trending jars, node-cron handles scheduled jobs, and optional S3 handles media. Playwright covers end-to-end testing, which for a payments flow is not optional in spirit.
The takeaway from PettyJar is that a joke of a product still demands serious infrastructure the moment money changes hands. The counter-act gimmick is what makes people smile, but it is the payout state machine, the anonymous auth, and the moderation tooling that decide whether the thing can actually run without hurting anyone or losing a dollar. Build the boring parts well and the fun parts get to exist.
Have something that needs building, or stabilizing?
These notes are the work log. The paid work runs through Moonshine Labs, my product and engineering studio. Tell us what you're building, or grab a call.
Work with us →