Bir Finans
A finance core that is exact to the last kuruş.



Screens are taken from a demo copy running on sample data; they contain no real customer data.
01 — Problem
For retainer clients, monthly packages, quota usage, extra work and revisions — along with collections, cheques, bank movements and VAT — were tracked in different places. Period close and client balances were calculated by hand every month.
02 — System
We built a work and finance application on a double-entry ledger in which every money record must balance debit against credit. Corrections are made by reversal, never deletion; amounts are stored as exact decimals, and foreign-currency documents post to the TRY ledger with TCMB rates and FX differences.
Period close
Every step from work entry to collection leaves a balanced ledger record.
- 01Work entry
- 02Quota calc
- 03Period close
- 04Receivable
- 05Collection
Correction → reversal entry
Bir Finans
Work entry
Quota calc
Period close
Receivable
Collection
03 — Architecture
The Next.js interface talks to a NestJS API over server-side sessions. Money POSTs carry idempotency keys, period close takes row locks, and every change lands in an audit log.
- L0Users
- Owner
- Admin
- Staff
- Viewer
- L1Interfaces
- Web app · PWA
- Reconciliation link
- L2Application
- NestJS 10
- Prisma 6
- Audit log
- L3Modules
- Ledger
- Accounts
- Documents
- Cash & bank
- Cheques & notes
- Quota engine
- Reports
- L4Data
- PostgreSQL 16
- DECIMAL(19,4)
- L5External services
- TCMB rate feed
04 — Capabilities
- 01
Double-entry ledger
No transaction is saved unless debit equals credit; typed accounts, a dedicated VAT account and void-by-reversal instead of deletion.
- 02
Current accounts
Customer, supplier, person and institution accounts; VKN/TCKN checksum validation, risk levels, Excel import/export, statements and netting/transfers.
- 03
Documents
Sales/purchase invoices, returns and quotes; line and document discounts, VAT inclusive/exclusive, numbering series, quote-to-invoice conversion and recurring documents.
- 04
Cash, bank, cheques
Statement import and matching that understands Turkish bank formats, cash counts; a full cheque and note lifecycle from portfolio to collection, endorsement or bounce, and a cheque calendar.
- 05
Quota and period engine
Contracts with price-version history, package/extra/hourly pricing, quota and revision overage; monthly period close and reopen with reason and audit.
- 06
Reconciliation and reports
A tokenised reconciliation page clients can agree to or dispute; aging, profit & loss, VAT, cash and audit reports in PDF and Excel.
05 — Impact
- 01
Period close and balance calculation for retainer clients are handled by the app.
- 02
Nothing is deleted; every correction is traceable in the ledger.
- 19,4
- decimal precision
- 42
- data models
- ~90
- application screens
- ~293
- test cases
Technology stack
Frontend
- Next.js 15.5
- React 19
- TanStack Query
- Radix UI
Backend
- NestJS 10
- Prisma 6
- Zod
- decimal.js
Data
- PostgreSQL 16
Documents
- Puppeteer
- ExcelJS
Infrastructure
- Docker Compose
- nginx
- Playwright

