Rule reference

BR-CO-13 BR-CO-13 requires the invoice total without VAT (BT-109) to equal Σ BT-131 − document allowances (BT-107) + document charges (BT-108)

BR-CO-13 requires the invoice total without VAT (BT-109) to equal Σ BT-131 − document allowances (BT-107) + document charges (BT-108). You declared 1.00 for BT-109, but the invoice lines compute to 1500.00 — a difference of -1499.00 EUR. This version of the library does not yet model document-level allowances or charges, so BT-109 must equal BT-106 exactly.

This rule is implemented and its error payload below is real, but the long-form write-up — normative text, worked example, divergence note — is not written yet. Everything the library knows about this rule is on this page. Ask and we will prioritise it.

Business term
BT-109
Severity
fatal

What the library returns

The exact object in result.errors when this rule fires. Generated by running @attestwire/en16931, not transcribed:

TeachingError
{
  "rule": "BR-CO-13",
  "field": "BT-109",
  "severity": "fatal",
  "message": "BR-CO-13 requires the invoice total without VAT (BT-109) to equal Σ BT-131 − document allowances (BT-107) + document charges (BT-108). You declared 1.00 for BT-109, but the invoice lines compute to 1500.00 — a difference of -1499.00 EUR. This version of the library does not yet model document-level allowances or charges, so BT-109 must equal BT-106 exactly.",
  "fix": "Either correct the line data so it sums to your declared figure, or drop declaredTotals.taxExclusiveAmount and let the library compute it. Note that EN 16931 sums *rounded* line amounts: round each line to 2 decimals first, then add — rounding only the final sum drifts by a cent or two on long invoices.",
  "example": "\"declaredTotals\": { \"taxExclusiveAmount\": 1500.00 }",
  "docsUrl": "https://attestwire.com/rules/BR-CO-13"
}

A passing value

the shape this field expects
"declaredTotals": { "taxExclusiveAmount": 1500.00 }

The fix

Either correct the line data so it sums to your declared figure, or drop declaredTotals.taxExclusiveAmount and let the library compute it. Note that EN 16931 sums *rounded* line amounts: round each line to 2 decimals first, then add — rounding only the final sum drifts by a cent or two on long invoices.

Arrived from a stack trace? The docsUrl on every error links straight here. Something wrong on this page — tell us.