What does BR-CO-24 mean?
Every charge on line level must carry a reason, either as text or as a code. That explains the charge.
Common causes of BR-CO-24
- The invoice line charge holds only an amount, but neither a reason text (BT-144) nor a reason code (BT-145).
- The charge reason was left out when the invoice was created, because it was assumed to be optional.
- An empty 'ram:Reason' element was written, which the validator treats as missing.
How to fix BR-CO-24
- Find the faulty spot in the XML. Open the XML of the invoice and go to field BG-28 along this XPath:
//ram:SpecifiedLineTradeSettlement/ram:SpecifiedTradeAllowanceCharge - Apply the fix. Every Invoice line charge (BG-28) needs a reason. In the line's 'ram:SpecifiedTradeAllowanceCharge' element (ChargeIndicator=true), add either a reason text 'ram:Reason' (BT-144) or a reason code 'ram:ReasonCode' (BT-145) from UNTDID 7161. At least one of the two must be set.
- Validate again. Save the file and validate it again to check that BR-CO-24 is no longer reported.
Every Invoice line charge (BG-28) needs a reason. In the line's 'ram:SpecifiedTradeAllowanceCharge' element (ChargeIndicator=true), add either a reason text 'ram:Reason' (BT-144) or a reason code 'ram:ReasonCode' (BT-145) from UNTDID 7161. At least one of the two must be set.
//ram:SpecifiedLineTradeSettlement/ram:SpecifiedTradeAllowanceChargeBefore / after: the XML example
This is the spot in question before and after the fix (Cross Industry Invoice, ZUGFeRD/Factur-X).
<ram:SpecifiedTradeAllowanceCharge>
<ram:ChargeIndicator><udt:Indicator>true</udt:Indicator></ram:ChargeIndicator>
<ram:ActualAmount>5.00</ram:ActualAmount>
</ram:SpecifiedTradeAllowanceCharge>
<ram:SpecifiedTradeAllowanceCharge>
<ram:ChargeIndicator><udt:Indicator>true</udt:Indicator></ram:ChargeIndicator>
<ram:ActualAmount>5.00</ram:ActualAmount>
<ram:ReasonCode>PC</ram:ReasonCode>
<ram:Reason>Verpackung</ram:Reason>
</ram:SpecifiedTradeAllowanceCharge>
Frequent questions about BR-CO-24
Is a reason code enough, or do I also need the reason text?
Which codes apply to invoice line charges?
Related error codes
Check BR-CO-24 automatically
Instead of digging through the XML by hand you can validate your ZUGFeRD or XRechnung file online – upload the PDF or the XML and you get every error with rule ID, affected field, fix and XPath, as a readable report or as JSON through the API.