Loans
Loans
Loans are canonical records used for bookkeeping review, posting, and period-based reporting. The goal is that the register remains stable and audit-friendly while automation depends on deterministic identifiers and references.
Ownership
Owner: bus loans. This module is responsible for implementing write operations for this object and is the only module that should directly change the canonical datasets for it.
Secondary read-only use cases are provided by these modules when they consume this object for validation, matching, posting, or reporting:
bus journal receives postings derived from loan events and amortization. bus entities provides referenced counterparties, and bus accounts provides accounts used by loan posting fields.
Actions
Register a loan records loan contracts so repayments and interest can be booked consistently. Record a loan event appends disbursements, repayments, interest, fees, and adjustments as auditable event history. Amortize a loan generates period amortization schedule and posting intent.
Properties
Core contract fields are loan_id, counterparty_id, principal_amount, start_date, maturity_date, and interest_rate.
Posting-account fields are principal_account_id, interest_account_id, and cash_account_id.
Relations
A loan belongs to the workspace’s accounting entity. Scope is derived from the workspace root directory rather than from a per-row key.
A loan references one party (lender or borrower) via counterparty_id.
A loan references ledger accounts via its account-id fields so that principal, interest, and cash movement can be posted consistently.
Amortization is produced for a given accounting period, based on the loan’s event history.