Rule reference

BR-CL-17 The VAT breakdown (BG-23) computed from your lines contains a VAT category code (BT-118) of "X", which is not in UNTDID 5305

The VAT breakdown (BG-23) computed from your lines contains a VAT category code (BT-118) of "X", which is not in UNTDID 5305. The breakdown categories are taken straight from the line categories (BT-151), so this is the document-level consequence of the same bad code — KoSIT reports it against both elements, and so do we.

This rule is implemented and its error payload below is real, but the long-form write-up — normative text, worked example, divergence note — is not written yet. Everything the library knows about this rule is on this page. Ask and we will prioritise it.

Business term
BT-118
Severity
fatal

What the library returns

The exact object in result.errors when this rule fires. Generated by running @attestwire/en16931, not transcribed:

TeachingError
{
  "rule": "BR-CL-17",
  "field": "BT-118",
  "severity": "fatal",
  "message": "The VAT breakdown (BG-23) computed from your lines contains a VAT category code (BT-118) of \"X\", which is not in UNTDID 5305. The breakdown categories are taken straight from the line categories (BT-151), so this is the document-level consequence of the same bad code — KoSIT reports it against both elements, and so do we.",
  "fix": "Correct the offending line's vatCategory. The breakdown is always computed from the lines, so there is nothing to fix at document level.",
  "example": "\"vatCategory\": \"S\", \"vatRate\": 19",
  "xpath": "/ubl:Invoice/cac:TaxTotal/cac:TaxSubtotal/cac:TaxCategory/cbc:ID",
  "docsUrl": "https://attestwire.com/rules/BR-CL-17"
}

xpath locates the element in the generated UBL document, which is where a KoSIT or Peppol validator will report the same problem.

A passing value

the shape this field expects
"vatCategory": "S", "vatRate": 19

The fix

Correct the offending line's vatCategory. The breakdown is always computed from the lines, so there is nothing to fix at document level.

Arrived from a stack trace? The docsUrl on every error links straight here. Something wrong on this page — tell us.