Backend walkthrough

A transaction ledger for Heisty

Behind Heisty, my daily logic puzzle, I built a general-ledger system to track each player's cash and gold balances. Rather than overwriting a single balance column, I record individual journal entries and derive beginning, ending, and intra-period balances from the transaction history — so the numbers are always auditable. This walkthrough goes through the schema and design decisions.

  • General ledger / journal entries
  • Per-user wallet transactions
  • Daily distribution table (idempotent upserts)
  • Supabase / Postgres
  • Instrumented with PostHog