Skip to content
syntaqx

Banking & Lending, chapter 01 of 76

The Banking & Lending Business

How banks, credit unions, fintechs and lenders work: the parties, how the money is made, the life of a deposit and a loan, and the core data model.

32 min readUpdated

Banking is two promises and a balance sheet. A depositor hands over money and is promised it back on demand, with interest, up to a limit the government insures. A borrower is handed money and promises it back on a schedule, with interest, under rules that say what the lender had to disclose, how it decided, and what it may do when payments stop. The institution in the middle earns the difference between what it pays for deposits and what it earns on loans, plus fees, plus interchange on the cards it issues, and it carries the risk that borrowers don't pay, that rates move against it, or that depositors all ask at once. A community bank, a credit union, a neobank on a sponsor bank, a mortgage lender that sells every loan it makes and a corporate card company that underwrites on a startup's cash balance are all doing some part of that, and each is regulated for the part it does.

The software is hard because the same dollar is recorded in several places that must agree to the cent. A deposit at a fintech exists in the fintech's ledger, the middleware's subledger, the sponsor bank's core, the bank's general ledger, the card processor's authorization balance and, if the bank fails, in the FDIC's insurance determination. A loan exists in the origination system that decided it, the servicing system that bills it, the bureaus it is reported to, the investor who bought it and the accounting that reserves for its losses. This chapter is the map the rest of the volume uses: how to read it, the parties, how the money is made, the life of a deposit and the life of a loan, and the data model every later chapter extends. Terms are collected in the volume's Glossary.

How to Read This Volume#

The volume follows money from the institution that holds it to the platform that runs it, in thirteen parts plus a reference:

The volume covers what banking and lending add. The general engineering lives in the playbook, and chapters link to it rather than repeat it: Money & Amounts, Payment States & Ledgers, Idempotency, Accounting, Temporal Data, Rules as Data, Events & Async Messaging, Reservations & Holds, Multi-Tenancy, Replacing Systems and Audit Trails. Other volumes own topics this one leans on. Payments owns the rails and the cards: ACH and Reg E for ACH (Consumer Law: Regulation E), checks and remote deposit (When the Money Is Available), card issuing and BIN sponsorship (Sponsor Banks Under Scrutiny), authorization, spend controls and cardholder disputes (Issuer Processing), a provider's own bank accounts and FBO basics (FBO Accounts and Pass-Through Insurance), and money transmission (Becoming a Payment Provider). Commerce owns BNPL at checkout and dealer F&I (F&I: Financing, Leases and Add-Ons); Property Tech owns tenant screening and rent reporting; and Field Operations owns financing sold at the door. This volume owns the account and the loan behind each of them: what the institution holds, owes, lends, discloses, reports and is examined on.

The volume is US-centric, with the UK and EU where their rules bind or teach. No single company is the model: the vocabulary and tables are the industry's, benchmarked across banks, credit unions, core vendors (Fiserv, FIS, Jack Henry, Temenos, Thought Machine, Mambu, 10x and others), sponsor banks and middleware, neobanks, lenders and spend platforms, and a company's own product name appears only where the chapter is describing that company.

Who's Who#

Party Who they are What they need from the system
Banks Chartered, FDIC-insured depository institutions, from money-center banks to community banks; 4,238 insured institutions at June 30, 2026, 3,818 of them community banks A ledger that is right every night, deposits they can lend against, losses they can reserve for, and records that survive an exam
Credit unions Member-owned cooperatives chartered by NCUA or a state and insured by the NCUSIF; 4,214 federally insured at June 30, 2026, with 146.1 million members The same as a bank, with members instead of customers and a field of membership that limits who may join
Sponsor banks Banks, usually under $10 billion in assets, that hold the accounts and issue the cards and loans of fintech programs Every program's customers identified, monitored and reconciled to the bank's core, because the bank's charter carries the obligations
Program managers and fintechs Companies that design, market and service a banking or lending product on a sponsor bank's charter: neobanks, business banking apps, spend platforms, embedded lenders A product they control, launched in months, with the bank's compliance requirements built in rather than bolted on
Middleware (BaaS platforms) Software between programs and banks that provides accounts, cards, payments and a subledger as an API Clean records of whose money is where, reconciled daily to each bank
Cores and processors Vendors that run the system of record for accounts and loans (Fiserv, FIS, Jack Henry, Temenos and newer cloud cores), plus card, payment and digital banking processors Postings and files in their formats, on their schedules
Lenders Banks lending from their balance sheet and nonbanks lending under state licenses or through bank partners: mortgage companies, auto finance companies, personal and small business lenders, BNPL providers Applications decided consistently, disclosed correctly, funded on time and serviced to the rules
Servicers and collectors Companies that bill and collect loans, sometimes for loans they don't own, and agencies that collect after delinquency or charge-off A loan ledger that allocates every payment the same way every time, and a record of every contact
Credit bureaus and data providers Experian, Equifax and TransUnion, the score developers (FICO, VantageScore), consumer reporting agencies for deposit accounts, and data aggregators Accurate furnished data, permissible purpose on every pull, and disputes answered on time
Investors and funders Depositors, warehouse lenders, forward-flow buyers, securitization investors, Fannie Mae, Freddie Mac and Ginnie Mae Loans that meet the criteria they bought, and reporting they can reconcile
Regulators The OCC, the Federal Reserve, the FDIC, NCUA, the CFPB, FinCEN, OFAC, state banking and lending regulators, and attorneys general Disclosures given, decisions explainable, money where the records say it is, crime reported, and every record on request

Three splits shape the data model. Institution versus program. The bank or credit union holds the deposit and owns the loan on its books; a program is a fintech's product running on that institution's charter, and the same customer may see only the fintech's brand. Every account belongs to exactly one institution and at most one program, and the institution's obligations (CIP, BSA, Reg E, deposit insurance records) follow the account wherever the program puts its logo. Party versus account. A person or business is a party; an account is a contract with the institution; the join between them carries the role (owner, joint owner, authorized signer, beneficiary, guarantor, co-borrower), and the role decides insurance coverage, who may move money, and who is liable. Deposit versus loan versus line. A deposit is money the institution owes the customer; a loan is money the customer owes on a schedule; a line is a limit the customer can draw and repay (a credit card, a HELOC, a business line). All three are accounts with balances and statements, and the direction of the debt flips how every posting, disclosure and regulation reads.

How the Money Works#

An institution earns money five ways, and most chapters in this volume regulate one of them. The figures below are from filings and agency data as of October 2026; the worked examples are illustrations, labeled as mine.

The spread

Net interest income is interest earned on loans and securities less interest paid on deposits and borrowings; net interest margin (NIM) is that amount over average earning assets. For all FDIC-insured institutions the second-quarter 2026 NIM was 3.32%, and 3.81% for community banks, on $26.5 trillion of assets and $20.7 trillion of deposits. Credit unions report the same idea against average assets rather than earning assets, so NCUA's figures don't compare directly (Bank Economics & Balance Sheet Risk covers the ratios).

A worked example of my own: a bank funds $1 billion of loans yielding 7.00% with $1 billion of deposits costing 2.00%. It earns $70 million of interest, pays $20 million, and keeps $50 million of net interest income before credit losses, salaries, technology and taxes. When the Federal Reserve cuts rates, loan yields and deposit costs both fall, but not at the same speed; how much of a rate change a bank passes to depositors is its deposit beta, and the spread lives or dies on it.

The data model consequence: interest is earned and owed daily, accrued in the ledger before it is paid, and computed to more decimal places than any customer ever sees. Reg DD lets an institution carry the daily rate and daily interest to five or more decimal places, while the APY earned on a statement uses the two-decimal amount actually paid, so accruals and postings are separate records.

Fees

Service charges, overdraft and NSF fees, wire and ATM fees, account analysis fees on business accounts, late fees and origination fees on loans. Fees are where much consumer law lands: Reg DD's statement totals for overdraft and returned-item fees, Reg E's opt-in for ATM and one-time debit overdrafts, the CARD Act's limits on card fees, state caps on loan fees. Every fee is a row with the schedule version that produced it (Overdraft, NSF & Fees and Products & Product Configuration cover the rules and the factory).

Interchange

When a customer pays with a debit or credit card the institution issued, the merchant's side pays the issuer interchange. Regulation II caps debit interchange for issuers with $10 billion or more in assets (with affiliates) at 21 cents plus 0.05% of the transaction, plus a fraud-prevention adjustment of up to 1 cent. On a $50 debit purchase a covered issuer may receive at most 21 + 2.5 + 1 = 24.5 cents; an exempt issuer's interchange is set by the networks. The Federal Reserve's data for 2024 put the average at $0.23 per covered transaction against $0.51 per exempt one.

That gap is a business model. Chime's 10-K says a substantial majority of its revenue comes from interchange; debit interchange alone was 49% of its $2,186.8 million of 2025 revenue, earned on cards issued by The Bancorp Bank and Stride Bank, both under the $10 billion line. The cap itself is moving: on October 26, 2026 the Eighth Circuit affirmed the vacatur of Regulation II's 21-cent standard in Corner Post v. Board of Governors and remanded to the Federal Reserve, a decision that takes effect only when the mandate issues, so as of October 2026 the cap still applies (Neobanks & Consumer Fintech tracks the litigation; The Economics covers how a card program shares interchange).

Gain on sale

A lender that sells the loans it makes earns the difference between the price an investor pays and the loan's cost to originate, and books it when the loan is sold rather than over its life. UWM originated $163.4 billion of mortgages in 2025 at a total gain margin of 116 basis points. Affirm's fiscal 2026 revenue of $4,261.1 million included $596.6 million of gain on sales of loans beside $2,047.5 million of interest income on the loans it kept, $1,149.9 million of merchant network revenue and $294.0 million of card network revenue: a BNPL lender is mostly a consumer lender, and how much it sells is a funding decision (Funding the Book covers forward flow and securitization).

Servicing

Whoever services a loan earns a fee for billing, collecting and reporting it, often as a share of the outstanding balance, and the right to that fee on a mortgage is an asset (a mortgage servicing right) that can be bought and sold. UWM reported $724.7 million of loan servicing income in 2025 on a portfolio of $240.8 billion of unpaid principal at year-end. Servicing is why the owner of a loan, the servicer and the institution that originated it are three separate columns on the loan record.

Credit losses

The cost that defines lending. Under CECL a lender reserves for the losses it expects over a loan's life when it books the loan, then charges off what isn't collected and records recoveries. Affirm's fiscal 2026 provision for credit losses was $796.7 million, about 39% of its interest income (my arithmetic). Some lenders measure new loans at fair value instead, which moves losses into the loan's price (Credit Losses & CECL covers both).

One rule for all of them

Most of the law in this volume regulates one of these lines: what rate was disclosed and how interest was computed, which fees were charged and whether the customer agreed, how interchange is shared, what was sold to whom, how a payment was applied, when a loss was recognized. My rule: every amount the institution earns or pays is a journal entry, and every customer-visible event is a transaction pointing at its journal entry, so the statement, the GL, the call report and the regulator's sample all read from the same rows. A balance computed any other way can't be reconciled, corrected, or defended.

The Life of a Deposit#

Opening. A person applies for a checking account in a bank's app or a fintech's. The application captures the CIP fields (name, date of birth, address, identification number), the system verifies them and screens the person against sanctions lists, a consumer reporting agency for deposit accounts may be checked, and the account is opened under a product version with its disclosures delivered and recorded: the Truth in Savings account disclosure, the Reg E disclosure, the funds availability policy, the privacy notice and, if the customer opts in, the overdraft notice (KYC & Account Opening and Deposit Accounts & Truth in Savings cover each). The account is titled in an ownership category, which decides how the FDIC insures it: $250,000 per depositor, per insured bank, per ownership category.

Funding. The customer's employer sends payroll by ACH. The core receives the file, posts a credit, and, for an electronic payment, must make the funds available by the business day after the banking day it received them. A mobile check deposit goes through remote deposit capture, and Reg CC requires the first $275 of a day's ordinary check deposits to be available the next business day, with the rest on a schedule the bank may extend with an exception hold and a notice (When the Money Is Available covers the check side; Funds Availability covers the account).

Spending. The customer taps a debit card. The issuer processor asks for an authorization, the core or the program's ledger checks the available balance, and an approval places a hold that reduces available balance without touching the ledger balance; the card network's clearing record later posts the debit and releases the hold. Bill payments, P2P sends and ACH debits post the same way, each a transaction with its own journal entry (Posting, Holds & Balances covers the three balances).

Earning. Each night the core accrues interest on the day's balance, and on the crediting date it posts the interest to the account. A worked example of my own: $10,000 kept for a year at a 4.00% rate compounded daily earns $408.08, so the account's APY is 100 × (408.08 / 10,000) = 4.08% under Reg DD's formula for a 365-day term, and the statement's APY earned is computed from the interest actually paid (Interest, APY & Statements covers the formulas).

Going wrong. The customer disputes a debit they didn't make. Reg E starts a clock: the error must be investigated and resolved within its deadlines, provisional credit given when the investigation runs long, the result reported, and the customer's liability capped by when they told the bank (Errors & Disputes on Deposit Accounts). A creditor's garnishment order arrives, and before freezing anything the bank must protect the federal benefits (Social Security, VA and similar) directly deposited in the two months before its review (Levies, Garnishments & Legal Process). The account goes quiet for years, and the bank must try to reach the owner before reporting the balance to the state as unclaimed property (Dormancy, Escheat & Closing Accounts).

Statements and closing. Every period produces a statement with the transactions, fees, overdraft and returned-item totals, interest and APY earned; each year the bank reports interest on a 1099-INT. The account closes at a zero balance, and the records stay for the retention periods each rule sets.

Across the life, one deposit is a contract (the account and its product version), a set of people (the account parties), a stream of transactions, a set of holds and a balance that must agree with the bank's general ledger every night. When a fintech program sits in between, it agrees with two ledgers, the program's and the bank's, and the FDIC's pass-through rules decide whether the customer is insured at all (FBO Accounts and Pass-Through Insurance; Program Ledgers & the Synapse Lesson covers what happens when they don't agree). In the Synapse collapse, the CFPB's complaint charged the middleware with "failing to maintain adequate records of the location of consumers' funds."

The Life of a Loan#

Application. A borrower applies for a $20,000 personal loan. The application records who applied, for what, and when it became complete, because the clocks in ECOA, TILA and the mortgage rules start there (Loan Origination). The lender pulls a credit report under a permissible purpose, verifies identity and income, and runs its decision engine: policy rules first (minimum score, maximum debt-to-income, state eligibility, the bank partner's criteria), then a model that scores and prices (Credit Data & Scores, Underwriting & Decision Engines).

Decision. The lender approves, counteroffers or declines. Reg B requires notice of the action within 30 days after a completed application; a decline or a counteroffer the applicant doesn't accept is adverse action and needs a notice with the principal reasons, and a decision that used a credit report adds the FCRA disclosures and, where required, the score (Adverse Action & Explaining Decisions). The decision record keeps every input, the model version, the policy version, the outcome and the reasons, because a fair lending exam samples them years later (Fair Lending, HMDA & 1071; Model Risk Management).

Disclosure and closing. The approved borrower sees the TILA disclosure (the APR, finance charge, amount financed, total of payments and payment schedule) before becoming obligated, signs electronically, and the loan is funded to their deposit account (APR, Finance Charges & Rate Caps; for mortgages, TRID & Mortgage Disclosures and Closing, eNotes & MERS). If a bank partner originated the loan, the program sends the loan to the bank, the bank funds it, and the program or an investor may buy it days later (Lender Licensing & Bank Partnerships).

Repayment. The loan boards to servicing with a schedule. A worked example of my own: $20,000 over 36 months at 12% a year (1% a month) amortizes to a payment of $664.29. The first payment is $200.00 of interest and $464.29 of principal; over the life the borrower pays about $3,914 of interest. Each payment is received, then allocated by the loan's rules (fees, interest, principal, in an order the contract and the law set), and the allocation is stored, not recomputed (Loan Servicing).

Delinquency and loss. A missed payment ages the loan through delinquency buckets; the servicer contacts the borrower within Reg F's limits, offers a hardship plan, and reports the status to the bureaus each month in Metro 2 (Collections & Recovery, Furnishing Credit Data). A loan that won't be collected is charged off on the schedule supervisory policy sets (for bank retail credit, at 120 cumulative days past due for closed-end loans and 180 for open-end, sooner after a bankruptcy notice or a fraud discovery), the allowance absorbs it, and any later recovery is booked as one (Credit Losses & CECL). A paid-off loan closes with a payoff, a lien release where there was collateral, and a final report to the bureaus.

Funding behind it. Throughout, someone owns the loan: the bank's balance sheet, a warehouse line, a forward-flow buyer, a securitization trust, or, for most US mortgages, a pool guaranteed by Fannie Mae, Freddie Mac or Ginnie Mae. Ownership can change while the borrower's servicer stays the same, and the servicer must report to each owner on its terms (Funding the Book, The Secondary Mortgage Market).

A credit card or a HELOC is a line rather than a loan: the account has a limit, draws and payments post as transactions, interest accrues on a balance computed by the method the agreement discloses, and a statement each cycle sets the minimum payment (Credit Cards as Credit). The data model treats it as an account with account_kind = 'line', with or without a loans row for its terms.

The Core Data Model#

Every company in this volume converges on the same concepts under different names: a core's customer information file, a BaaS platform's customer and a lender's borrower are all parties; a core's DDA, a middleware wallet and a servicing system's loan are all accounts; a core's GL posting, a cloud core's posting instruction and a program's ledger transaction are all journal entries. The volume uses one set of names, and every later chapter's "How to Build It" extends it rather than redefining it:

Entity Table What it is
institution institutions A bank or credit union: charter type, primary regulator, FDIC certificate or NCUA charter number, RSSD ID
program programs A fintech's product on an institution's charter: the program manager, the bank, the product scope
party parties A person or a business
party identity party_identities A verified identifier (SSN, EIN, passport, phone, email) with the verification method and KYC result
product products A versioned deposit, loan or line product definition: rates, fees, limits, terms, disclosures
account accounts One deposit, loan or line account, under one product version, at one institution, in at most one program
account party account_parties A party's role on an account: owner, joint owner, authorized signer, beneficiary, guarantor, co-borrower
GL account gl_accounts The institution's chart of accounts
journal entry and line journal_entries, journal_lines Double entry for every money movement, balanced to zero
transaction transactions The customer-visible activity row, linked to its journal entry
hold holds An amount set aside from available balance, with a reason and an expiry
balance snapshot balance_snapshots End-of-day ledger, available and collected balances per account
interest accrual interest_accruals Interest earned or owed for a day, before it is posted
fee assessment fee_assessments A fee charged, waived or refunded, with the schedule that produced it
statement statements A periodic statement as issued
disclosure disclosures What was shown or sent, which version, when, and how
application applications An application for a deposit account or credit
credit decision credit_decisions A decision's inputs, model and policy versions, outcome and reasons
loan loans The terms of a loan or line account: principal, rate, term, amortization method
payment schedule and installment payment_schedules, schedule_installments The schedule a loan is billed on, and each amount due
loan payment and allocation loan_payments, payment_allocations A payment received, and how it was applied
collateral collateral What secures a loan: a vehicle, a property, a deposit, a lien on business assets
case cases A dispute, error claim, fraud claim, legal process, complaint or investigation, with its clock and outcome

Seven splits matter in every chapter:

  • Institution versus program. The institution is regulated and holds the books; the program is a product on top. A program's customer is still the institution's customer for CIP, BSA, Reg E and insurance purposes, which is why accounts.institution_id is never null and program_id is optional.
  • Party versus account versus role. One person can own a checking account, be an authorized signer on her company's account and guarantee its loan. Roles live on account_parties, never on the party, and a business's owners and controllers are parties linked to it, not fields on it. The Investing & Digital Assets volume uses the same parties and account_parties split (The Core Data Model).
  • Product versus product version versus account. A product changes; an account opened under version 3 keeps version 3's terms until the institution sends a change-in-terms notice and moves it. Every account points at the exact version it is on.
  • Transaction versus journal entry. A transaction is what the customer sees ("Payroll, $2,400"); its journal entry is the double-entry truth (debit the settlement GL, credit the customer's deposit liability). A reversal is a new transaction and a new entry, never an edit.
  • Ledger balance versus available balance versus collected balance. Ledger is posted transactions; available is ledger minus holds plus any funds the institution makes available early; collected is what has actually cleared. They are computed from transactions and holds, and snapshotted at end of day because statements, interest and overdraft decisions read a specific day's value.
  • Accrued versus posted interest. Interest accrues daily to more precision than money has and posts on a schedule in minor units; the difference is a rounding the institution must handle the same way every time.
  • Owed versus paid versus applied. A schedule says what is due; a payment says what arrived; an allocation says what it paid off. A loan's balance is the sum of its allocations, not a column someone updated.

The spine, in the playbook's naming conventions, with amounts in integer minor units (Money & Amounts); columns each chapter owns are added there:

CREATE TABLE institutions (                -- a bank or credit union
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  legal_name          TEXT NOT NULL,
  kind                TEXT NOT NULL CHECK (kind IN ('bank', 'savings_institution',
                        'credit_union', 'industrial_bank', 'trust_bank')),
  charter_type        TEXT NOT NULL CHECK (charter_type IN ('national', 'state_member',
                        'state_nonmember', 'federal_savings', 'state_savings',
                        'federal_credit_union', 'state_credit_union', 'industrial_loan',
                        'national_trust', 'state_trust')),
  primary_regulator   TEXT NOT NULL CHECK (primary_regulator IN ('occ', 'frb', 'fdic',
                        'ncua', 'state')),
  charter_state       CHAR(2),               -- null for a federal charter
  fdic_cert           INT UNIQUE,            -- null for a credit union or uninsured trust bank
  ncua_charter        INT UNIQUE,            -- null for a bank
  rssd_id             INT UNIQUE,            -- the Federal Reserve's identifier
  routing_numbers     TEXT[] NOT NULL DEFAULT '{}',  -- ABA routing numbers it owns
  insured             BOOLEAN NOT NULL,
  status              TEXT NOT NULL CHECK (status IN ('active', 'merged', 'failed', 'closed')),
  created_at          TIMESTAMPTZ NOT NULL DEFAULT NOW()
);

CREATE TABLE programs (                    -- a fintech's product on an institution's charter
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  institution_id      UUID NOT NULL REFERENCES institutions (id),
  program_manager     TEXT NOT NULL,         -- the brand the customer sees
  middleware          TEXT,                  -- the BaaS platform in between, if any
  name                TEXT NOT NULL,
  product_scope       TEXT[] NOT NULL,       -- e.g. {'deposit', 'debit_card', 'credit_line'}
  agreement_ref       TEXT NOT NULL,         -- the program agreement, as a document
  status              TEXT NOT NULL CHECK (status IN ('onboarding', 'live', 'restricted',
                        'winding_down', 'exited')),
  valid_during        TSTZRANGE NOT NULL,
  UNIQUE (institution_id, name)
);

CREATE TABLE parties (                     -- a person or a business
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  kind                TEXT NOT NULL CHECK (kind IN ('person', 'business')),
  legal_name          TEXT NOT NULL,
  date_of_birth       DATE,                  -- persons only
  formation_date      DATE,                  -- businesses only
  entity_type         TEXT,                  -- 'llc', 'corporation', 'sole_prop', ...
  status              TEXT NOT NULL CHECK (status IN ('prospect', 'active', 'restricted',
                        'deceased', 'dissolved', 'closed')),
  created_at          TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  CHECK (kind = 'person' OR date_of_birth IS NULL)
);

CREATE TABLE party_identities (            -- verified identifiers and KYC results
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  party_id            UUID NOT NULL REFERENCES parties (id),
  kind                TEXT NOT NULL CHECK (kind IN ('ssn', 'itin', 'ein', 'passport',
                        'drivers_license', 'phone', 'email', 'address')),
  value_token         TEXT NOT NULL,         -- vaulted; the playbook's sensitive-data rules
  value_last4         TEXT,
  method              TEXT NOT NULL,         -- 'documentary', 'non_documentary', 'ecbsv', ...
  vendor_ref          TEXT,                  -- the verification vendor's result ID
  result              TEXT NOT NULL CHECK (result IN ('verified', 'failed', 'review',
                        'expired')),
  verified_at         TIMESTAMPTZ NOT NULL,
  UNIQUE (party_id, kind, value_token)
);

CREATE TABLE products (                    -- versioned product definitions
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  institution_id      UUID NOT NULL REFERENCES institutions (id),
  program_id          UUID REFERENCES programs (id),  -- null: the institution's own product
  code                TEXT NOT NULL,         -- stable across versions, e.g. 'CHK-BASIC'
  version             INT NOT NULL CHECK (version > 0),
  account_kind        TEXT NOT NULL CHECK (account_kind IN ('deposit', 'loan', 'line')),
  category            TEXT NOT NULL,         -- 'checking', 'savings', 'cd', 'personal_loan', ...
  currency            CHAR(3) NOT NULL,
  terms               JSONB NOT NULL,        -- rates, tiers, fees, limits, day count
  valid_during        TSTZRANGE NOT NULL,    -- when new accounts may open on this version
  UNIQUE (institution_id, code, version)
);

CREATE TABLE accounts (                    -- one deposit, loan or line account
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  institution_id      UUID NOT NULL REFERENCES institutions (id),
  program_id          UUID REFERENCES programs (id),
  product_id          UUID NOT NULL REFERENCES products (id),  -- the exact version
  account_kind        TEXT NOT NULL CHECK (account_kind IN ('deposit', 'loan', 'line')),
  number_token        TEXT NOT NULL,         -- vaulted account number
  number_last4        TEXT NOT NULL,
  ownership_category  TEXT CHECK (ownership_category IN ('single', 'joint', 'retirement',
                        'trust', 'employee_benefit', 'business', 'government')),
  custodial           BOOLEAN NOT NULL DEFAULT FALSE,  -- titled for others: pass-through
  currency            CHAR(3) NOT NULL,
  status              TEXT NOT NULL CHECK (status IN ('pending', 'active', 'dormant',
                        'restricted', 'frozen', 'charged_off', 'closed')),
  opened_at           TIMESTAMPTZ,
  closed_at           TIMESTAMPTZ,
  UNIQUE (institution_id, number_token),
  CHECK (account_kind = 'deposit' OR ownership_category IS NULL)
);

CREATE TABLE account_parties (             -- who is on the account, and as what
  account_id          UUID NOT NULL REFERENCES accounts (id),
  party_id            UUID NOT NULL REFERENCES parties (id),
  role                TEXT NOT NULL CHECK (role IN ('owner', 'joint_owner',
                        'authorized_signer', 'beneficiary', 'guarantor', 'co_borrower',
                        'beneficial_owner', 'custodian')),
  share               NUMERIC(7, 4),         -- a beneficiary's or co-owner's interest, if stated
  valid_during        TSTZRANGE NOT NULL,
  PRIMARY KEY (account_id, party_id, role, valid_during)
);

CREATE TABLE gl_accounts (                 -- the institution's chart of accounts
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  institution_id      UUID NOT NULL REFERENCES institutions (id),
  number              TEXT NOT NULL,
  name                TEXT NOT NULL,
  type                TEXT NOT NULL CHECK (type IN ('asset', 'liability', 'equity',
                        'income', 'expense')),
  normal_side         TEXT NOT NULL CHECK (normal_side IN ('debit', 'credit')),
  report_line         TEXT,                  -- the call report line it rolls up to
  UNIQUE (institution_id, number)
);

CREATE TABLE journal_entries (             -- one balanced money movement
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  institution_id      UUID NOT NULL REFERENCES institutions (id),
  kind                TEXT NOT NULL,         -- 'ach_credit', 'card_settlement', 'interest_post', ...
  effective_date      DATE NOT NULL,         -- the business date it counts for
  posted_at           TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  reverses_id         UUID REFERENCES journal_entries (id),
  source_ref          TEXT,                  -- the file, message or request that caused it
  idempotency_key     TEXT NOT NULL,
  UNIQUE (institution_id, idempotency_key)
);

CREATE TABLE journal_lines (               -- debits and credits; each entry sums to zero
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  journal_entry_id    UUID NOT NULL REFERENCES journal_entries (id),
  gl_account_id       UUID NOT NULL REFERENCES gl_accounts (id),
  account_id          UUID REFERENCES accounts (id),  -- the subledger: null for pure GL lines
  amount              BIGINT NOT NULL CHECK (amount <> 0),  -- debit positive, credit negative
  currency            CHAR(3) NOT NULL
);

CREATE TABLE transactions (                -- what the customer sees
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES accounts (id),
  journal_entry_id    UUID NOT NULL REFERENCES journal_entries (id),
  kind                TEXT NOT NULL,         -- 'ach_credit', 'card_purchase', 'fee', 'interest', ...
  direction           TEXT NOT NULL CHECK (direction IN ('credit', 'debit')),
  amount              BIGINT NOT NULL CHECK (amount > 0),
  description         TEXT NOT NULL,         -- as shown on the statement
  counterparty        JSONB,                 -- merchant, originator or payee, as received
  rail                TEXT,                  -- 'ach', 'card', 'wire', 'rtp', 'fednow', 'check', 'book'
  rail_ref            TEXT,                  -- trace number, network reference, IMAD
  effective_date      DATE NOT NULL,
  posted_at           TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  reverses_id         UUID REFERENCES transactions (id)
);

CREATE TABLE holds (                       -- reduces available balance, not ledger balance
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES accounts (id),
  amount              BIGINT NOT NULL CHECK (amount > 0),
  reason              TEXT NOT NULL CHECK (reason IN ('card_authorization', 'deposit_availability',
                        'legal_process', 'fraud', 'collateral', 'manual')),
  source_ref          TEXT,                  -- the authorization, deposit or case
  placed_at           TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  expires_at          TIMESTAMPTZ,           -- null: until released
  released_at         TIMESTAMPTZ,
  release_reason      TEXT CHECK (release_reason IN ('settled', 'expired', 'reversed',
                        'released'))
);

CREATE TABLE balance_snapshots (           -- end of day, per account
  account_id          UUID NOT NULL REFERENCES accounts (id),
  business_date       DATE NOT NULL,
  ledger_balance      BIGINT NOT NULL,
  available_balance   BIGINT NOT NULL,
  collected_balance   BIGINT NOT NULL,
  PRIMARY KEY (account_id, business_date)
);

CREATE TABLE interest_accruals (           -- a day's interest, before it posts
  account_id          UUID NOT NULL REFERENCES accounts (id),
  business_date       DATE NOT NULL,
  balance_basis       BIGINT NOT NULL,       -- the balance the rate applied to
  annual_rate         NUMERIC(9, 6) NOT NULL,  -- 0.040000 for 4%
  day_count           TEXT NOT NULL,         -- 'actual_365', 'actual_360', ...
  amount              NUMERIC(20, 6) NOT NULL,  -- minor units, unrounded
  posted_in_id        UUID REFERENCES journal_entries (id),  -- set when credited or billed
  PRIMARY KEY (account_id, business_date)
);

CREATE TABLE fee_assessments (
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES accounts (id),
  kind                TEXT NOT NULL,         -- 'overdraft', 'nsf', 'wire', 'late', 'origination', ...
  amount              BIGINT NOT NULL CHECK (amount > 0),
  schedule_ref        TEXT NOT NULL,         -- the product version's fee rule
  trigger_ref         TEXT,                  -- the transaction or event that triggered it
  status              TEXT NOT NULL CHECK (status IN ('assessed', 'waived', 'refunded')),
  transaction_id      UUID REFERENCES transactions (id),
  assessed_at         TIMESTAMPTZ NOT NULL DEFAULT NOW()
);

CREATE TABLE statements (                  -- as issued, never regenerated
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES accounts (id),
  period              DATERANGE NOT NULL,
  opening_balance     BIGINT NOT NULL,
  closing_balance     BIGINT NOT NULL,
  totals              JSONB NOT NULL,        -- interest, APY earned, fees by type, period and YTD
  document_ref        TEXT NOT NULL,         -- object storage key of the rendered statement
  delivered_via       TEXT NOT NULL CHECK (delivered_via IN ('electronic', 'mail')),
  issued_at           TIMESTAMPTZ NOT NULL,
  UNIQUE (account_id, period)
);

CREATE TABLE disclosures (                 -- what was shown or sent, version, when, how
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  kind                TEXT NOT NULL,         -- 'truth_in_savings', 'reg_e', 'overdraft_opt_in',
                                             -- 'funds_availability', 'tila', 'adverse_action', ...
  template_version    TEXT NOT NULL,
  party_id            UUID NOT NULL REFERENCES parties (id),
  account_id          UUID REFERENCES accounts (id),
  application_id      UUID,                  -- applications, below
  channel             TEXT NOT NULL CHECK (channel IN ('screen', 'email', 'mail', 'in_person',
                        'sms')),
  esign_consent_ref   TEXT,                  -- the E-SIGN consent it relied on, if electronic
  document_ref        TEXT NOT NULL,         -- the rendered document, as delivered
  delivered_at        TIMESTAMPTZ NOT NULL,
  acknowledged_at     TIMESTAMPTZ
);

CREATE TABLE applications (                -- for a deposit account or credit
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  institution_id      UUID NOT NULL REFERENCES institutions (id),
  program_id          UUID REFERENCES programs (id),
  product_id          UUID NOT NULL REFERENCES products (id),
  kind                TEXT NOT NULL CHECK (kind IN ('deposit', 'credit')),
  channel             TEXT NOT NULL,         -- 'online', 'branch', 'broker', 'dealer', 'partner'
  requested_amount    BIGINT,
  received_at         TIMESTAMPTZ NOT NULL,
  completed_at        TIMESTAMPTZ,           -- when it became a completed application
  status              TEXT NOT NULL CHECK (status IN ('started', 'submitted', 'complete',
                        'decided', 'withdrawn', 'incomplete_closed')),
  account_id          UUID REFERENCES accounts (id)  -- the account it opened, if any
);

CREATE TABLE credit_decisions (            -- inputs, versions, outcome, reasons
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  application_id      UUID REFERENCES applications (id),
  account_id          UUID REFERENCES accounts (id),  -- a line increase or review
  kind                TEXT NOT NULL CHECK (kind IN ('origination', 'counteroffer',
                        'line_change', 'review')),
  policy_version      TEXT NOT NULL,
  model_version       TEXT,
  inputs_ref          TEXT NOT NULL,         -- the frozen input snapshot: reports, attributes
  outcome             TEXT NOT NULL CHECK (outcome IN ('approved', 'counteroffered',
                        'declined', 'referred')),
  terms               JSONB,                 -- amount, rate, term offered
  reasons             TEXT[] NOT NULL DEFAULT '{}',  -- principal reasons, in order
  decided_by          TEXT NOT NULL,         -- 'system' or the underwriter
  decided_at          TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  CHECK (application_id IS NOT NULL OR account_id IS NOT NULL)
);

CREATE TABLE loans (                       -- terms extending a loan or line account
  account_id          UUID PRIMARY KEY REFERENCES accounts (id),
  principal           BIGINT NOT NULL CHECK (principal > 0),  -- original amount or limit
  annual_rate         NUMERIC(9, 6) NOT NULL,
  rate_type           TEXT NOT NULL CHECK (rate_type IN ('fixed', 'variable')),
  index_ref           TEXT,                  -- 'prime', 'sofr_30d_avg' for variable rates
  margin              NUMERIC(9, 6),
  apr                 NUMERIC(9, 6),         -- as disclosed
  term_months         INT,                   -- null for an open-ended line
  amortization        TEXT NOT NULL CHECK (amortization IN ('level_payment',
                        'daily_simple_interest', 'interest_only', 'revolving',
                        'fixed_fee', 'percent_of_sales')),
  owner               TEXT NOT NULL,         -- 'institution', an investor or trust ID
  servicer            TEXT NOT NULL,
  originated_at       DATE NOT NULL,
  maturity_date       DATE
);

CREATE TABLE payment_schedules (           -- a version of what the borrower owes when
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES loans (account_id),
  version             INT NOT NULL,          -- a new version on modification or re-amortization
  reason              TEXT NOT NULL,         -- 'origination', 'modification', 'deferral', ...
  valid_during        TSTZRANGE NOT NULL,
  UNIQUE (account_id, version)
);

CREATE TABLE schedule_installments (
  payment_schedule_id UUID NOT NULL REFERENCES payment_schedules (id),
  sequence            INT NOT NULL,
  due_date            DATE NOT NULL,
  principal_due       BIGINT NOT NULL,
  interest_due        BIGINT NOT NULL,
  fees_due            BIGINT NOT NULL DEFAULT 0,
  escrow_due          BIGINT NOT NULL DEFAULT 0,
  PRIMARY KEY (payment_schedule_id, sequence)
);

CREATE TABLE loan_payments (               -- money received against a loan
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES loans (account_id),
  amount              BIGINT NOT NULL CHECK (amount > 0),
  method              TEXT NOT NULL,         -- 'autopay_ach', 'card', 'check', 'payout_withholding'
  received_at         TIMESTAMPTZ NOT NULL,
  effective_date      DATE NOT NULL,         -- the date interest stops on it
  transaction_id      UUID NOT NULL REFERENCES transactions (id),
  status              TEXT NOT NULL CHECK (status IN ('received', 'applied', 'returned',
                        'reversed'))
);

CREATE TABLE payment_allocations (         -- how each payment was applied, stored not recomputed
  loan_payment_id     UUID NOT NULL REFERENCES loan_payments (id),
  bucket              TEXT NOT NULL CHECK (bucket IN ('fees', 'interest', 'principal',
                        'escrow', 'unapplied')),
  amount              BIGINT NOT NULL,
  installment_ref     INT,                   -- the installment it satisfied, if any
  rule_ref            TEXT NOT NULL,         -- the allocation rule version
  PRIMARY KEY (loan_payment_id, bucket, installment_ref)
);

CREATE TABLE collateral (                  -- what secures a loan
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  account_id          UUID NOT NULL REFERENCES loans (account_id),
  kind                TEXT NOT NULL CHECK (kind IN ('real_property', 'vehicle', 'deposit',
                        'securities', 'equipment', 'receivables', 'blanket_lien')),
  description         TEXT NOT NULL,
  identifier          TEXT,                  -- VIN, parcel number, account ID
  value               BIGINT,
  valued_at           DATE,
  lien_ref            TEXT,                  -- title, recorded mortgage or UCC-1 filing number
  lien_position       SMALLINT,
  released_at         TIMESTAMPTZ
);

CREATE TABLE cases (                       -- disputes, claims, legal process, complaints
  id                  UUID PRIMARY KEY DEFAULT uuidv7(),
  kind                TEXT NOT NULL CHECK (kind IN ('reg_e_error', 'reg_cc_claim',
                        'billing_error', 'fraud_claim', 'credit_report_dispute', 'legal_process',
                        'complaint', 'aml_investigation', 'hardship')),
  party_id            UUID REFERENCES parties (id),
  account_id          UUID REFERENCES accounts (id),
  opened_at           TIMESTAMPTZ NOT NULL,  -- when notice was received: the clock starts here
  rule_ref            TEXT NOT NULL,         -- the rule whose deadlines apply
  due_at              TIMESTAMPTZ,           -- the next deadline, computed and stored
  status              TEXT NOT NULL CHECK (status IN ('open', 'pending_customer',
                        'resolved', 'closed')),
  outcome             TEXT,
  closed_at           TIMESTAMPTZ
);

Design notes:

  • The institution is on every row that matters. Accounts, products, applications, GL accounts and journal entries carry institution_id, because one platform often serves several banks (a core vendor, a BaaS platform, a program that moved banks) and a bank's records must be producible alone. That is the volume's tenancy: Multi-Tenancy with the institution above the program.
  • Balances are computed, then snapshotted. Ledger balance is the sum of an account's journal lines; available balance subtracts open holds; both are derived. balance_snapshots freezes each business date's values because statements, interest, Reg CC and overdraft decisions are judged against a specific day, and a later correction must not silently rewrite it.
  • Business date is not wall-clock time. effective_date and business_date are the institution's processing calendar: a deposit after the cutoff on Friday counts on Monday's business date. Holidays, cutoffs and the difference between a calendar day and a business day are data (Cutoffs, Calendars and the Business Date covers the calendar).
  • Precision lives in accruals; money lives in entries. interest_accruals.amount carries six decimal places of a minor unit; posting rounds once into a journal entry, per the rule the product version names, as Reg DD's rounding conventions require.
  • Allocations are facts. A loan's principal balance is the sum of principal allocations, and payment_allocations stores how each payment was applied under the rule in force that day. Recomputing allocations after an allocation rule changes rewrites history the borrower and the bureaus already saw.
  • A disclosure is a record, not a template. disclosures stores the rendered document as delivered, the template version and the channel, with the E-SIGN consent it relied on (Electronic Signatures). Proving what the customer saw is the most common demand an examiner makes.
  • Cases carry their clock. Reg E, Reg CC, Reg Z billing errors, FCRA disputes and legal process each start a deadline at notice. cases.opened_at is when notice arrived, and due_at is computed from the rule and stored (Deadlines Are Computed and Stored).
  • Reuse the Payments model at the edges. The Payments volume's bank_accounts are a provider's own accounts at banks; an FBO account is a bank_accounts row to the provider and a custodial accounts row to the bank. A Payments card_accounts row points at the accounts row that carries its balance, and cards, card_programs, spend_control_rules and cardholder_disputes stay where Card Issuing and Issuer Processing define them. The provider's ledger_entries and the institution's journal_lines are two sets of books for the same money, and Ledger & Reconciliation is how they are matched.
  • Emit life-cycle events. account.opened, transaction.posted, hold.placed, hold.released, statement.issued, application.completed, credit_decision.made, loan.boarded, loan_payment.applied and case.opened are what notifications, monitoring, reporting and the bureaus subscribe to (The Transactional Outbox).

Each later chapter extends a defined part of this spine. The chapters and the tables each one extends are below; each chapter's How to Build It names the tables it adds:

Chapter Extends
The Banking Landscape institutions; adds institution_events, technology_providers, institution_providers
Bank Economics & Balance Sheet Risk gl_accounts, balance_snapshots, interest_accruals; adds policy_rates, alm_positions, alm_assumption_sets, alm_runs
Charters & Regulators institutions; adds institution_supervisors, state_law_applicability
Starting a Bank institutions, programs; adds regulatory_approvals, approval_conditions, condition_tests, business_plan_projections
Exams, Ratings & Call Reports institutions, gl_accounts; adds examinations, supervisory_findings, finding_milestones, enforcement_actions, regulatory_filings
When Banks Fail institutions, accounts, account_parties; adds failure_readiness_extracts, bank_exposures
Core Banking Systems gl_accounts, journal_entries, journal_lines, accounts; adds gl_mappings, subledger_proofs, gl_exports
Posting, Holds & Balances transactions, holds, balance_snapshots, journal_entries; adds memo_posts, posting_order_rules, business_days, eod_steps, balance_decisions
Interest, APY & Statements interest_accruals, statements, products; adds interest_accrual_adjustments, interest_credits, tax_reportables, tax_forms
Products & Product Configuration products, accounts, disclosures; adds product_rate_tiers, product_fees, account_terms, account_promotions, term_changes, term_change_accounts
Core Modernization & Conversions accounts, journal_lines, balance_snapshots; adds conversions, conversion_runs, conversion_crosswalk, conversion_product_mappings, conversion_controls, conversion_in_flight
Deposit Accounts & Truth in Savings products, accounts, disclosures; adds time_deposit_terms, time_deposits
Deposit Insurance accounts, account_parties, programs; adds insurance_determinations, insurance_lines
Funds Availability holds, transactions, disclosures; adds availability_rules, deposit_items, availability_decisions
Overdraft, NSF & Fees fee_assessments, transactions, holds, disclosures; adds overdraft_consents, overdraft_decisions
Errors & Disputes on Deposit Accounts cases, transactions, journal_entries, disclosures; adds error_claims, case_deadlines, provisional_credits
Dormancy, Escheat & Closing Accounts accounts, transactions, disclosures; adds unclaimed_property_rules, owner_activity, escheat_items, account_closures, death_notices, benefit_reclamations
Levies, Garnishments & Legal Process cases, holds, accounts; adds legal_orders, legal_order_accounts, records_productions
KYC & Account Opening parties, party_identities, applications; adds identity_verifications, cip_determinations, deposit_screenings, party_relationships
BSA/AML Programs transactions, cases, parties; adds customer_risk_profiles, monitoring_rules, alerts, alert_transactions, monitoring_ingest, aml_investigations, bsa_restricted, currency_aggregates, ctr_filings, ctr_exemptions, fincen_314a_requests
Sanctions Screening parties, party_identities, transactions; adds sanctions_list_versions, sanctions_list_entries, screenings, screening_hits, sanctions_actions, sanctions_derived_blocks
Account Takeover & Scams cases, transactions, party_identities; adds account_security_events, payment_interventions, fraud_claims, inbound_fraud_reports, trusted_contacts, exploitation_reports
Neobanks & Consumer Fintech programs, accounts; adds institution_asset_tests, program_revenue_terms, program_revenue_statements
Banking as a Service programs, institutions, accounts; adds program_participants, program_obligations, program_reserves, program_migrations, account_migrations
Program Ledgers & the Synapse Lesson programs, accounts, journal_lines, balance_snapshots; adds owner_balance_files, owner_balance_lines, omnibus_reconciliations, reconciliation_items
Sponsor Bank Oversight programs, cases; adds program_reviews, obligation_tests, program_limits
Earned Wage Access products, accounts, fee_assessments; adds ewa_employers, wage_accruals, ewa_advances, ewa_recoveries, ewa_state_rules
Credit Builders & Secured Products loans, accounts, collateral; adds secured_credit_terms, graduation_reviews, collateral_releases
Open Banking in the US parties, accounts, disclosures; adds data_connections, data_authorizations, linked_payment_accounts, data_pulls, third_party_registrations, data_access_grants, tokenized_account_numbers, interface_performance_months
Open Banking in the UK & EU parties, accounts, disclosures; adds consent_reconfirmations, ais_access_events
The Lending Business loans; adds pricing_grids, pricing_grid_cells, loan_pricing, loan_economics_monthly
Credit Cards as Credit accounts, loans, interest_accruals, fee_assessments, statements; adds credit_lines, balance_segments, billing_cycles, segment_daily_balances, rate_changes, credit_limit_changes
Personal & Installment Loans loans, payment_schedules, schedule_installments; adds loan_disbursements, payoff_quotes, rate_cap_rules, rate_cap_evaluations, payment_transfer_attempts
Auto Lending loans, collateral; adds dealers, dealer_agreements, indirect_contracts, contract_products, product_refunds, leases, lien_records, repossessions
Mortgages & Home Equity loans, collateral, applications, credit_lines; adds mortgage_terms, property_valuations, rate_locks, rate_lock_events, atr_qm_determinations, mortgage_insurance, rescission_periods, originator_assignments
Student Loans loans, payment_schedules, loan_disbursements; adds student_loan_terms, school_certifications, income_certifications, repayment_plan_enrollments, plan_enrollment_loans, payment_pauses, qualifying_months, subsidy_postings, loan_discharges
Buy Now, Pay Later loans, payment_schedules, disclosures; adds bnpl_merchant_agreements, pos_financing_terms, merchant_settlements, plan_adjustments, credit_regimes
Small Business Lending accounts (adds the purchase kind), account_parties, collateral; adds receivable_purchases, reconciliation_requests, guarantees, ucc_filings, sba_guarantees, equipment_finance_terms, factored_invoices
Embedded Lending loans, loan_payments, programs, disclosures; adds distribution_partners, financing_offers, withholding_instructions, withholdings, repayment_floors, commercial_disclosure_rules, commercial_disclosures, provider_registrations
Commercial Lending loans, accounts, loan_payments; adds credit_facilities, facility_tranches, facility_lenders, lender_distributions, financial_spreads, covenants, covenant_tests, borrowing_base_certificates, risk_ratings, credit_reviews, lending_limit_checks
Loan Origination applications, parties, disclosures; adds application_parties, application_data_versions, application_stage_events, application_documents, verifications, application_conditions
Credit Data & Scores applications, credit_decisions, party_identities; adds credit_report_pulls, credit_scores, representative_scores, prescreen_campaigns
Underwriting & Decision Engines credit_decisions, applications; adds decision_policies, decision_rule_results, model_outputs, repayment_assessments, decision_experiments, decision_overrides
Adverse Action & Explaining Decisions credit_decisions, disclosures; adds reason_codes, feature_reason_map, decision_notices, notice_reasons, notice_report_disclosures, reason_requests
Fair Lending, HMDA & 1071 applications, credit_decisions; adds demographic_responses, hmda_lar_records, sblar_records, fair_lending_tests
Model Risk Management credit_decisions; adds model_inventory, model_versions, model_validations, model_findings, model_monitoring_runs
APR, Finance Charges & Rate Caps loans, disclosures, rate_cap_rules; adds finance_charge_rules, apr_computations, covered_borrower_checks, scra_benefits
TRID & Mortgage Disclosures applications, disclosures; adds legal_public_holidays, closing_cost_items, changed_circumstances, disclosure_deadlines, tolerance_cures
Closing, eNotes & MERS loans, collateral, disclosures; adds closings, closing_documents, notarizations, enotes, enote_control_transfers, post_closing_items
Loan Servicing loans, loan_payments, payment_allocations, payment_schedules; adds loan_boardings, allocation_rules, loan_roles_history, loan_autopay_enrollments, servicing_transfers, servicing_transfer_loans
Mortgage Servicing, Escrow & Loss Mitigation loans, schedule_installments, cases; adds escrow_accounts, escrow_items, escrow_analyses, escrow_disbursements, loss_mitigation_applications, loss_mitigation_decisions, foreclosure_referrals, forbearance_periods
Furnishing Credit Data accounts, loans, cases; adds reporting_profiles, furnishing_runs, tradeline_snapshots, furnishing_suppressions, credit_report_disputes
Collections & Recovery loans, schedule_installments, cases; adds delinquency_snapshots, collection_contacts, contact_restrictions, hardship_plans, legal_stays, agency_placements, debt_sales, debt_sale_accounts
Credit Losses & CECL loans, gl_accounts, journal_entries; adds loss_pools, allowance_assumptions, allowance_runs, allowance_pool_results, charge_offs, recoveries, fair_value_marks
Funding the Book loans, programs, journal_entries; adds funding_vehicles, funding_vehicle_rules, loan_funding_allocations, loan_transfers, borrowing_base_reports, investor_reports
The Secondary Mortgage Market loans, collateral, funding_vehicles, loan_transfers; adds agency_commitments, mbs_pools, agency_deliveries, servicing_rights, servicer_advances
Lender Licensing & Bank Partnerships institutions, programs, products, applications; adds license_requirements, lender_licenses, originator_registrations, license_checks
Business Accounts & Startup Banking parties, account_parties, accounts; adds platform_users, user_grants, payment_approval_rules, payment_approvals, security_procedure_elections
Sweeps, Reciprocal Deposits & Yield accounts, balance_snapshots, institutions; adds sweep_programs, sweep_program_banks, sweep_exclusions, sweep_placements, sweep_movements, investment_sweeps
Treasury Management accounts, transactions, fee_assessments; adds tm_enrollments, tm_declinations, issued_checks, tm_exceptions, balance_transfer_rules, analysis_statements, analysis_lines, report_code_mappings
The Spend Management Business programs, fee_assessments, Payments' card_programs; reuses program_revenue_terms, program_revenue_statements; adds card_rewards_rules, card_rewards_entries, card_program_economics_monthly
Corporate Cards & Underwriting accounts, credit_decisions, credit_limit_changes, Payments' card_accounts; adds corporate_card_terms, card_funding_sources, limit_evaluations, card_receivable_participations
Virtual Cards & Spend Controls Payments' cards and spend_control_rules; adds spend_programs, spend_budgets, budget_periods, budget_entries, card_scopes, spend_program_rules, spend_requests
Receipts, Expense Policy & Audit transactions, Payments' clearing_records; adds expense_policies, expenses, expense_receipts, receipt_matches, expense_policy_evaluations, expense_approvals
Reimbursements, Mileage & Per Diem parties, transactions, expenses; adds reimbursement_rates, accountable_plans, mileage_trips, per_diem_claims, expense_advances, reimbursements, reimbursement_items, employee_repayments
AP, Bill Pay & Procurement parties, Payments' vendors, bills and disbursements, Commerce's purchase_orders and receipts, expense_approvals; adds purchase_requests, bill_lines, match_tolerances, bill_line_matches
Business Travel & Duty of Care parties, party_identities, expenses; adds travel_policies, trips, travel_bookings, booking_charges, ticket_credits, traveler_checkins
Accounting Sync & the Close parties, expenses, bills; adds erp_connections, erp_accounts, erp_dimensions, erp_dimension_values, coding_rules, line_codings, erp_sync_records, close_periods
Banking Architecture every table, the playbook's outbox_events; adds rail_calendars, rail_cutoffs, inbound_messages, account_positions, invariant_checks
Digital & Mobile Banking parties, accounts, disclosures; adds digital_enrollments, authenticators, step_up_rules, alert_subscriptions, alert_deliveries, bill_payees, bill_payments
Regulatory Reporting & Data gl_accounts, applications, cases, regulatory_filings; adds report_obligations, report_line_definitions, report_line_values, report_adjustments, filing_submissions, report_edit_results
Security, Resilience & Incident Notice institutions, programs, technology_providers; adds notification_regimes, security_incidents, incident_notifications, critical_operations, operation_dependencies
AI in Banking & Lending credit_decisions, cases, model_inventory; adds ai_use_cases, assistant_sessions, assistant_actions, rights_signals, assistant_evaluations
Banking & Lending Metrics balance_snapshots, loans, schedule_installments, delinquency_snapshots; adds metric_definitions, metric_values

Three decisions keep the map one model rather than several:

  • One account table for every direction of debt. A checking account, a personal loan, a credit card and a HELOC are all accounts rows; loans extends the ones with lending terms. Splitting deposits and loans into separate systems is the history core modernization is still undoing, and one table lets a customer's whole relationship, a secured card's deposit and its line, or a sweep and its source account be one query.
  • One case table for every clock. Reg E errors, credit report disputes, levies, complaints and AML investigations differ in their rules, not their shape: a notice, a deadline, work, an outcome. Each chapter adds its own detail table keyed by cases.id rather than a parallel queue.
  • One disclosure table for every notice. Account disclosures, change-in-terms notices, adverse action notices, TILA and TRID forms and privacy notices are all disclosures rows, so "show me everything this customer was told" is one query.

Chapters change tables that already hold rows, so their ALTERs are written to run on a live database: checks, required columns and foreign keys on existing columns are added NOT VALID, which checks new rows without scanning the old ones, and indexes and unique keys are built CONCURRENTLY. Once any backfill is done, each NOT VALID constraint is validated under a lock that doesn't block reads or writes (Zero-Downtime Migrations). For the check AP, Bill Pay & Procurement adds to receipts:

ALTER TABLE receipts VALIDATE CONSTRAINT receipts_kind_check;

Auditing#

The records in this chapter are the ones examiners, auditors, the FDIC, investors and courts ask about later:

  • Whose money is where. Every account with its institution, program, ownership category, custodial flag and parties over time, so an insurance determination or a program exit can be run from the records alone.
  • Every money movement, balanced. Every journal entry with lines that sum to zero, its business date, its source and its reversal, and every transaction pointing at one; the GL must tie to the sum of account subledgers every day (Payment States & Ledgers).
  • What the customer was told. Every disclosure as delivered, with its version, channel and consent, and every statement as issued.
  • How every decision was made. Every credit decision with its frozen inputs, policy and model versions, outcome and reasons, and every fee with the schedule that produced it.
  • Every clock and how it ended. Every case with when notice arrived, the deadline the rule set, the actions taken and the outcome.

The mechanics (typed actors, append-only history, tamper evidence) are in Audit Trails.

What This Means for the System You Build#

  • Put the institution on every account, product and entry, and treat a program as a product on the institution's charter, never as the holder of the account.
  • Model parties, accounts and roles separately, with roles effective-dated on the join, because insurance, authority and liability all follow the role.
  • Pin every account to a product version and move it only with a recorded change-in-terms notice.
  • Make every money movement a balanced journal entry and every customer-visible row a transaction that points at one; reverse, never edit.
  • Compute ledger, available and collected balances from entries and holds, and snapshot them per business date.
  • Accrue interest daily at full precision and round once when it posts.
  • Store payment allocations as they were made, under the rule in force that day.
  • Record every disclosure as delivered and every decision with its inputs and versions.
  • Start every regulatory clock at notice and store its deadline.
  • Reuse the Payments model for the provider's bank accounts, cards and card disputes instead of rebuilding it.

References#

Law and regulation

Regulators and data

Filings

Courts