SchemaGuard by Ironbark Digital · EN 16931 / Peppol / XRechnung Reference
← All 294 EN 16931 / Peppol Rules & Live Validator
FATAL Official EN 16931 / Peppol / CIUS Rule BT/BG Fields: BT-148

BR-28 — E-Invoice Validation Rule & Fix

Fixture ID: negativeGrossPrice · XPath: /ubl:Invoice/cac:InvoiceLine[1]/cac:Price/cac:AllowanceCharge/cbc:BaseAmount

1. Why This Rule Triggers (Diagnostic Message)

Line 1 (id "1") has a negative item gross price (BT-148: -200). The gross price is the list price *before* the item price discount (BT-147) is taken off, so it is the larger of the two figures by construction — a negative one means the sign has been applied at the wrong end. EN 16931 models every reduction as an allowance or a discount, never as a negative price, and BR-27 says the same thing about the net price (BT-146).

2. How to Fix BR-28

Set line.grossUnitPrice to the positive list price and line.priceDiscount to the reduction. If the price genuinely is the net price, omit grossUnitPrice entirely — this build derives the discount as grossUnitPrice − unitPrice when you do not state it.

3. Valid Code / Payload Example

"grossUnitPrice": 200, "priceDiscount": 50, "unitPrice": 150
Test & Validate XML / JSON in Live SchemaGuard Validator →