OT
OpenTeq
Start Free Trial
← All 4 Architecture Pillars
PILLAR 03

Append-Only Zero-Sum Double-Entry Accounting Engine

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.

8
Canonical Ledger Accounts
0%
Floating-Point Math
$0.00
Trial Balance Drift

Technical Specification

8 Canonical Accounts

accounts_receivable, clearing_ach, clearing_card, merchant_cash, revenue, platform_fees, refunds_returns, and chargeback_losses.

trg_ledger_immutable (Append-Only)

BEFORE UPDATE OR DELETE trigger blocks all historical mutations—adjustments and ACH returns must post balanced reversing transaction groups.

trg_ledger_balanced_commit (Zero-Sum)

DEFERRABLE INITIALLY DEFERRED constraint trigger verifies SUM(debits) - SUM(credits) = 0 per transaction_group_id before PostgreSQL commits.

Technical FAQ

How does OpenTeq represent currency to avoid rounding errors?
All monetary values are stored as PostgreSQL bigint minor units (cents) and TypeScript BigInt paired with a 3-letter ISO-4217 currency code.

OpenTeq Agents Powered by This Pillar

#06 • WAVE 1Zero unbalanced journal drift

Real-Time Double-Entry Ledger Watchdog

Continuously audits zero-sum debit/credit balance and clearing account staleness.

ledger.audit.zero_sumledger.clearing.inspect+1 more
$899.00/moTenant
Specs
#10 • WAVE 25-day close cut to 2 hours

Monthly Close O2C Subledger Reconciler

Automates month-end AR subledger tie-out and exports controller close workpapers.

close.subledger.tie_outclose.unapplied_cash.match+1 more
$1,499.00/moTenant
Specs
#14 • WAVE 2Audit-grade ASC 606 automation

ASC 606 Deferred Revenue & Waterfall Agent

Computes ratable ASC 606 recognition schedules and posts monthly waterfall journals.

revrec.schedules.computerevrec.journal.post+1 more
$1,599.00/moTenant
Specs
#15 • WAVE 2Multi-entity consolidation in mins

Multi-Entity Intercompany O2C Eliminations

Detects intercompany AR/AP pairs, computes FX variance, and posts eliminations.

interco.pairs.detectinterco.fx_variance.compute+1 more
$1,799.00/moTenant
Specs

Ready to deploy autonomous Order-to-Cash across your NetSuite & Stripe Connect stack?

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.