Skip to content
All work

Mobile and backend · Travel

Tour Board

Group trip planning with shared expenses, balances, settlements and a day by day itinerary on a map. Live on Google Play.

Role
Sole engineer
Timeline
2026
Type
Mobile and backend · Travel
Company
Independent product
FlutterRiverpodFirebaseCloud FirestoreNode.jsTypeScriptGoogle Maps
Tour Board screenshot

What the product does

On a group trip, money moves in every direction. One person pays for the hotel, another for dinner, a third for the train, and by the last day nobody is sure who owes whom. On our own trip to Cox's Bazar that ledger lived in a WhatsApp group, and settling up took an evening of scrolling.

Tour Board gives the group one shared space. Members record expenses as they happen, see live balances in every currency the trip uses, and settle with as few transfers as possible. The same space holds the itinerary, plotted day by day on a map, along with notes, a packing list and an activity feed. We tested it on our own trip first, and settling up took two minutes.

What I built

The Flutter application, the Firestore data model and security rules, and a small Node.js and TypeScript backend. Both are open source: the app and the backend. Thirteen features: auth, tours, membership and roles, expenses, settlements, itinerary, map, notes, packing list, activity feed, notifications, settings and home.

The interesting engineering

The security boundary is the rules file, not the app. Firestore accepts writes straight from the phone, so the client is treated as untrusted. Every write is validated in firestore.rules: shape, types, bounds, immutable fields, membership, role and ownership. Related documents have to be written atomically in one batch, which the rules enforce with getAfter. A suite of 46 tests runs against the Firestore emulator, so a rule cannot be loosened by accident.

Money is integers, splits are deterministic. Amounts are stored in minor units and only divided for display. Participants are sorted by user ID before a split, equal split remainders go to the first IDs, and weighted splits use the largest remainder method, so every device computes the same shares and the parts always sum to the whole. Currencies are never merged, and every currency's balances net to zero.

Settling up in at most n minus 1 transfers. Balances are derived from confirmed expenses and settlements. A greedy pass pairs the largest debtor with the largest creditor until everyone is at zero. A settlement is a two step handshake: one member submits it, the other confirms or disputes it.

A backend only for what a phone cannot do safely. The TypeScript service verifies that a reported event really happened in Firestore before it sends push notifications, and delivers each event once. It runs a daily retention job and proxies Google Places search, so the server key never ships in the app, with caching and per user rate limits. The whole system runs on free tiers.

Listeners only live while a screen needs them. Firestore streams are auto disposing Riverpod providers keyed by tour, and the workspace builds only the selected tab. Read counts, and the bill, stay small.