Fixing total-amount rules
Most rejected invoices fail because one total does not equal the sum it is built from. The rules compare exact decimal values after rounding to two decimals, so a difference of one cent is enough.
The chain of totals
Recompute the totals in this order, each from the values before it, and round each result to two decimals:
- Line net amount (BT-131) of each line. Peppol rule PEPPOL-EN16931-R120 requires it to equal quantity × (net price ÷ price base quantity) + line charges − line allowances, within 0.02.
- Sum of line net amounts (BT-106) = the sum of all BT-131 (BR-CO-10).
- Total without VAT (BT-109) = BT-106 − document allowances (BT-107) + document charges (BT-108) (BR-CO-13).
- Total VAT (BT-110) = the sum of the VAT amounts of each VAT breakdown (BR-CO-14). Each breakdown amount is its taxable amount × rate, rounded per category, not per line.
- Total with VAT (BT-112) = BT-109 + BT-110 (BR-CO-15).
- Amount due (BT-115) = BT-112 − paid amount (BT-113) + rounding amount (BT-114) (BR-CO-16).
Typical causes
- VAT computed per line and summed, while the standard rounds per VAT category. The sum of rounded line VAT can differ by a cent or more.
- Totals copied from the accounting system instead of being recomputed from the lines that are actually in the XML.
- Prices with more than two decimals multiplied by large quantities, then truncated instead of rounded.
- A document-level discount applied to the total but not written as an allowance (BG-20).
Check the fix
Run the corrected file through the free validator. In a workspace, upload it again: the report of the new version lists the findings that were fixed.