Real-Time Double-Entry Ledger Watchdog
Continuously audits zero-sum debit/credit balance and clearing account staleness.
Integer minor-unit (bigint cents) precision with database-guaranteed zero-sum commits.
OpenTeq replaces mutable invoice flags and floating-point spreadsheet math with an 8-account canonical double-entry ledger enforced by PostgreSQL immutability and deferrable commit balance triggers.
accounts_receivable, clearing_ach, clearing_card, merchant_cash, revenue, platform_fees, refunds_returns, and chargeback_losses.
BEFORE UPDATE OR DELETE trigger blocks all historical mutations—adjustments and ACH returns must post balanced reversing transaction groups.
DEFERRABLE INITIALLY DEFERRED constraint trigger verifies SUM(debits) - SUM(credits) = 0 per transaction_group_id before PostgreSQL commits.
Continuously audits zero-sum debit/credit balance and clearing account staleness.
Automates month-end AR subledger tie-out and exports controller close workpapers.
Computes ratable ASC 606 recognition schedules and posts monthly waterfall journals.
Detects intercompany AR/AP pairs, computes FX variance, and posts eliminations.
Start with a single Wave 1 agent or equip a complete role blueprint. Every tenant runs on forced PostgreSQL RLS and zero-sum double-entry accounting.