Skip to content

docs: AGENTS.md matches the AR posting and the credit gate - #116

Merged
futurebuildai merged 2 commits into
refactor/v1from
refactor/docs-agents-ar-drift
Oct 11, 2026
Merged

futurebuildai merged 2 commits into
refactor/v1from
refactor/docs-agents-ar-drift

Conversation

@futurebuildai

@futurebuildai futurebuildai commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

AGENTS.md named functions and accounts that do not exist, and described the credit gate and the fulfilment's GL entry wrongly. Each line now states what the code has:

  • the module count: 54 directories under core/internal, 47 domain modules (docs/architecture.md), not about 40;
  • the credit-limit gate: OpenReceivableCents in the order repository (open invoices and open credit memos by amount open, less unapplied cash, plus the unbilled remainder of the customer's other live orders), run at confirm (the order's own total; over the limit parks it ON_HOLD) and at fulfil (the order's unbilled remainder; over the limit a 409), not at create; there is no order.Service.overCreditLimit;
  • the AR subledger: the account package is its single writer, through account.Service.subledger; RecordPayment posts the receipt to cash and customer deposits and reaches the subledger only through the applications sent with it; there is no account.PostTransaction, order.FulfillOrder or payment.ProcessPayment;
  • the fulfilment's GL entry: DR Accounts Receivable and DR Cost of Goods Sold against CR revenue, CR Sales Tax Payable and CR Inventory, posted by account.Service.PostInvoice (not the two leg gl.SyncInvoice entry); POS completion posts its cash collected portion through gl.SyncCashSale;
  • the portal's money TODOs: portal/model.go carries several, not one at line 61;
  • the section heading now says the AR is derived from documents.

🤖 Generated with Claude Code

futurebuildai and others added 2 commits October 10, 2026 22:15
…osting the code has

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: colton <colton@futurebuild.ai>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: colton <colton@futurebuild.ai>
@futurebuildai
futurebuildai merged commit 53a375d into refactor/v1 Oct 11, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant