Peppol BIS Billing 3.0.20 · UBL

BR-CO-22: Each Document level charge (BG-21) shall contain a Document level charge reason (BT-104)…

Peppol BIS Billing 3.0.20 · UBL

fatalbusiness

Original rule text

[BR-CO-22]-Each Document level charge (BG-21) shall contain a Document level charge reason (BT-104) or a Document level charge reason code (BT-105), or both.

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

BR-CO-22 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-21, BT-104, BT-105.

What this rule requires

The rule requires that every document level charge (BG-21) contains at least one of a document level charge reason (BT-104) or a document level charge reason code (BT-105), or both. In UBL this means each cac:AllowanceCharge with cbc:ChargeIndicator = true must have a child cbc:AllowanceChargeReason or cbc:AllowanceChargeReasonCode. A document fails validation when neither element exists.

How to fix

Add cbc:AllowanceChargeReason or cbc:AllowanceChargeReasonCode (or both) to each cac:AllowanceCharge where cbc:ChargeIndicator is true. In CII, add ram:Reason or ram:ReasonCode under the applicable ram:SpecifiedTradeAllowanceCharge with ram:ChargeIndicator true. The rule only checks for the element's presence, not its 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-22.

Validate an invoice against these rules · All release changes