Skip to content
Justin O'Halloran

Work / Burrard Works (client: a Bitcoin ATM operator)

A FIFO cost-basis engine for a Bitcoin ATM operator

Monthly exports from ATMs, an exchange and a hot wallet in; FIFO cost basis, gains and an accountant-ready workbook out, validated to the cent across 284 disposals.

Role
Founder and engineer
When
Feb 2026 – present
Stack
Next.jsTypeScriptExcel generationClaude Code
Validation
To the cent, 284 disposals
Measured
Against the client's reference baseline
In production
Q1 2026 reporting delivered
Measured
Still operated and iterated

The problem

The client runs a network of Bitcoin ATMs and an exchange. Each month their accountant needs cost basis and realised gains for business-income reporting to the CRA, and the raw material is three sets of exports (ATM, exchange and hot wallet) that were never designed to agree with each other.

What I built

  • An ingestion layer that normalises the three exports into one ledger of acquisitions and disposals.
  • A FIFO engine that matches each disposal against open lots in order and computes cost basis and gain per lot.
  • Output the accountant can use without me: a summary plus a multi-tab, reconciled Excel workbook.

The rewrite

Months two and three broke on data states the model had no mapping for, and the cause turned out to be structural: the hot wallet, not the exchange, was the tier-1 dataset. I rewrote the engine around it. After the rewrite the output matched the client's own reference baseline to the cent across all 284 disposals.

How it was built

I wrote the specification first (architecture, data spec, and validation criteria) and built from it with Claude Code, prompt-driven, without writing code by hand. The spec is what made that safe: the validation baseline was defined before the engine existed, so "done" meant matching it, not looking plausible.