Peppol BIS Billing 3.0.20 · UBL

BR-CO-23: Each Invoice line allowance (BG-27) shall contain an Invoice line allowance reason…

Peppol BIS Billing 3.0.20 · UBL

fatalbusiness

Original rule text

[BR-CO-23]-Each Invoice line allowance (BG-27) shall contain an Invoice line allowance reason (BT-139) or an Invoice line allowance reason code (BT-140), or both.

Stored validation assertion
exists(cbc:AllowanceChargeReason) or exists(cbc:AllowanceChargeReasonCode)

BR-CO-23 is a fatal rule in the business layer of Peppol BIS Billing 3.0.20 · UBL. An invoice that breaks it is rejected. It refers to BG-27, BT-139, BT-140.

What this rule requires

For each invoice line allowance (BG-27), represented by a cac:AllowanceCharge with cbc:ChargeIndicator set to false (or the equivalent CII structure), the rule requires at least one of cbc:AllowanceChargeReason (BT-139) or cbc:AllowanceChargeReasonCode (BT-140) to be present. Because the test uses or, either element alone is sufficient; both is also allowed. The severity is fatal, so an invoice missing both in any line allowance does not pass validation.

How to fix

Add a cbc:AllowanceChargeReason element or a cbc:AllowanceChargeReasonCode element (or both) inside each line-level cac:AllowanceCharge where cbc:ChargeIndicator is false. In CII, add ram:Reason or ram:ReasonCode within the corresponding ram:SpecifiedTradeAllowanceCharge. The rule only checks for the presence of at least one of these elements, not its value or content.

Guidance on this rule. The original text above is authoritative.

Where to go next

No published Peppol BIS Billing UBL release comparison lists a change to BR-CO-23.

Validate an invoice against these rules · All release changes