Peppol BIS Billing 3.0.21 · UBL

BR-CL-20: Coded charge reasons MUST belong to the UNCL 7161 code list

Peppol BIS Billing 3.0.21 · UBL

fatalbusiness

Original rule text

[BR-CL-20]-Coded charge reasons MUST belong to the UNCL 7161 code list

Stored validation assertion
((not(contains(normalize-space(.), ' ')) and contains(' AA AAA AAC AAD AAE AAF AAH AAI AAS AAT AAV AAY AAZ ABA ABB ABC ABD ABF ABK ABL ABN ABR ABS ABT ABU ACF ACG ACH ACI ACJ ACK ACL ACM ACS ADC ADE ADJ ADK ADL ADM ADN ADO ADP ADQ ADR ADT ADW ADY ADZ AEA AEB AEC AED AEF AEH AEI AEJ AEK AEL AEM AEN AEO AEP AES AET AEU AEV AEW AEX AEY AEZ AJ AU CA CAB CAD CAE CAF CAI CAJ CAK CAL CAM CAN CAO CAP CAQ CAR CAS CAT CAU CAV CAW CAX CAY CAZ CD CG CS CT DAB DAD DAC DAF DAG DAH DAI DAJ DAK DAL DAM DAN DAO DAP DAQ DL EG EP ER FAA FAB FAC FC FH FI GAA HAA HD HH IAA IAB ID IF IR IS KO L1 LA LAA LAB LF MAE MI ML NAA OA PA PAA PC PL PRV RAB RAC RAD RAF RE RF RH RV SA SAA SAD SAE SAI SG SH SM SU TAB TAC TT TV V1 V2 WH XAA YY ZZZ ', concat(' ', normalize-space(.), ' '))))

BR-CL-20 is a fatal rule in the business layer of Peppol BIS Billing 3.0.21 · UBL. An invoice that breaks it is rejected.

What this rule requires

The rule requires that a coded charge reason (cbc:AllowanceChargeReasonCode in UBL or ram:ReasonCode in CII) on a charge (ChargeIndicator = true) be a single code from the UNCL 7161 list given in the rule. Ignoring surrounding whitespace, the value must not contain internal spaces and must exactly match one of the listed codes, for example AA, AAA, AAC. If the value is not one of the listed codes, or contains internal spaces, the document fails this fatal rule.

How to fix

Set the charge reason code element to a valid UNCL 7161 code from the rule's list. In UBL, this is cbc:AllowanceChargeReasonCode inside cac:AllowanceCharge where cbc:ChargeIndicator is true; in CII, it is ram:ReasonCode inside ram:SpecifiedTradeAllowanceCharge where ram:ChargeIndicator is true. Replace any free-text description or unknown code with the appropriate single code from the list, and ensure no multiple codes or internal spaces are entered. Check your code mapping or configuration for the correct charge reason code.

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-CL-20.

Validate an invoice against these rules · All release changes