Fixture ID: declaredAllowanceTotals · XPath: /ubl:Invoice/cac:LegalMonetaryTotal/cbc:ChargeTotalAmount
BR-CO-12 requires BT-108 to equal Σ BT-99, the sum of the BG-21 amounts on the document. You declared 1.00 for BT-108, but the single entry in charges sum to 5.00 — a difference of -4.00 EUR. Line level charges (BG-28) are deliberately not in this sum — they are already inside the line net amounts that make up BT-106, and counting them again here would double them into BT-109 via BR-CO-13.
BR-CO-12Either correct the charges array so it sums to your declared figure, or drop declaredTotals.chargeTotalAmount and let the library compute it — generation always emits the computed value regardless of what you declare. Sum the *rounded* entry amounts, in that order: EN 16931 rounds each amount to two decimals and then adds.
"declaredTotals": { "chargeTotalAmount": 5.00 }