Reference
Markdown exportPEPPOL-EN16931-R130 Price base unit code must match invoiced quantity unit code
Under Peppol rule PEPPOL-EN16931-R130, whenever an invoice line specifies an item price base quantity unit of measure code in BT-150 (unitCode on BaseQuantity), its value must be identical to the invoiced quantity unit of measure code in BT-130 (unitCode on InvoicedQuantity). In electronic trade, mixing different units of measure on the same line (such as billing quantity in "H87" pieces while pricing in "KGM" kilograms without conversion) creates ambiguity in automated pricing calculations. Both unitCode attributes must share the same UN/ECE Rec 20 / Rec 21 code.
Problem Description
ERROR
Peppol BIS Billing 3.0 rule (OpenPeppol)
Interactive pipeline
Where PEPPOL-EN16931-R130 is checked
Click a stage to see what it checks, or type a rule ID to light up the stage that reports it.
PEPPOL-EN16931-R130 Peppol BIS Billing rule
Reported in stage 3: National rules (CIUS).
Level error: the report recommends rejecting the invoice.
Stage 3 · What it checks
National rules (CIUS)
- The specification identifier in BT-24 selects the rule set, for example XRechnung 3.0 or Peppol BIS Billing 3.0.
- XRechnung adds the German BR-DE rules: buyer reference (BT-10), seller contact, payment instructions.
- Peppol adds PEPPOL-EN16931 and country rules. XRechnung applies some PEPPOL-EN16931 rules too.
Example codes
Typical fix
Fill the fields the rule set requires in your master data, such as the Leitweg-ID in BT-10 or the seller contact.
Solution
In your ERP product catalog or unit conversion settings, align the unit of the price base quantity (BT-150) with the line billing unit (BT-130). In UBL 2.1, make sure <cbc:BaseQuantity unitCode="H87"> carries exactly the same unitCode attribute as <cbc:InvoicedQuantity unitCode="H87">. If the price applies to one unit, you may omit cbc:BaseQuantity entirely.
Quick actions
Context and Significance
PEPPOL-EN16931-R130 only runs when cbc:BaseQuantity is present and compares its unitCode with the unitCode of the invoiced quantity. Different units on one line make the unit price calculation ambiguous, for example a quantity in hours priced per piece. The error usually appears when the price list stores a different unit than the order line, or when a default unit such as C62 is written into BaseQuantity.
Valid Examples
- InvoicedQuantity unitCode = "H87" (piece) and BaseQuantity unitCode = "H87" (piece)
- InvoicedQuantity unitCode = "HUR" (hour) and BaseQuantity unitCode = "HUR" (hour)
Invalid Examples
- InvoicedQuantity specified in "HUR" (hours) while Price BaseQuantity specifies unitCode = "C62" (one)
- InvoicedQuantity specified in "KGM" (kilograms) while Price BaseQuantity specifies unitCode = "LTR" (liters)
Code Examples
<cac:InvoiceLine>
<cbc:ID>1</cbc:ID>
<cbc:InvoicedQuantity unitCode="H87">100</cbc:InvoicedQuantity>
<cac:Price>
<cbc:PriceAmount currencyID="EUR">50.00</cbc:PriceAmount>
<cbc:BaseQuantity unitCode="H87">100</cbc:BaseQuantity>
</cac:Price>
</cac:InvoiceLine><cac:InvoiceLine>
<cbc:ID>1</cbc:ID>
<cbc:InvoicedQuantity unitCode="H87">100</cbc:InvoicedQuantity>
<cac:Price>
<cbc:PriceAmount currencyID="EUR">50.00</cbc:PriceAmount>
<cbc:BaseQuantity unitCode="C62">100</cbc:BaseQuantity>
</cac:Price>
</cac:InvoiceLine>