Project system

Transaction-safe backend

Banking Ledger System

Independent build

00 / Project overview

What it is

A ledger-first banking backend where account balances are derived from immutable double-entry records instead of being edited directly.

Problem it solves

Directly editing an account balance makes retries, partial failures and duplicate requests difficult to audit safely. The ledger system records every movement as an immutable double-entry transaction so balances remain traceable and consistent.

01 / Challenge

The constraint that shaped the build.

Money movement has to remain correct when requests retry, fail halfway through or arrive more than once. A mutable balance field alone cannot provide that guarantee or a reliable audit trail.

02 / Approach

Make the rules visible.

I centered the architecture on journal entries and transaction boundaries. Idempotency keys protect repeated requests, while database sessions keep each transfer atomic.

Core product flow
01

Immutable double-entry ledger

02

Idempotent transfer requests

03

Atomic MongoDB transaction sessions

04

JWT authentication and OAuth2 notifications

Technical composition
01Node.js02Express.js03MongoDB04JWT05bcrypt06Gmail OAuth2

03 / Solution

The finished system.

Backend developerProject-based

The MERN backend uses MongoDB transactions, JWT authentication and bcrypt password hashing. Gmail OAuth2 notifications sit outside the transaction-critical path.

Outcome

The architecture makes the ledger the source of truth and gives every balance a traceable history of entries.