# BR-32 Document level allowance VAT category code is required

Each Document level allowance (BG-20) shall have a Document level allowance VAT category code (BT-95).

## Problem Description

> **ERROR**: EN 16931 core business rule (CEN)

## Context and Significance

This is an EN 16931 core rule. A document level allowance reduces the taxable amount of one specific VAT category. Without the category code (BT-95) the validator cannot assign the allowance to a line of the VAT breakdown (BG-23), and the taxable amounts no longer reconcile. The error often appears when the discount is exported as a plain amount without tax data, for example a flat discount added in the invoice footer.

## Solution

Add cac:TaxCategory/cbc:ID (CII: ram:CategoryTradeTax/ram:CategoryCode) to the allowance, using the VAT category of the goods or services it reduces. If the allowance covers several VAT rates, split it into one allowance per category.

- [Validate XML](/en/xrechnung-validator?source=resource&rule=BR-32)
- [Convert invoice](/en/pdf-to-xrechnung?source=resource&rule=BR-32)

## Valid Examples

- BT-95 = S (standard rate) on a document level allowance

## Invalid Examples

- Document allowance amount present but no BT-95 category code

## Code Examples

### Valid XML
```
<cac:AllowanceCharge>
  <cbc:ChargeIndicator>false</cbc:ChargeIndicator>
  <cbc:Amount currencyID="EUR">20.00</cbc:Amount>
  <cac:TaxCategory>
    <cbc:ID>S</cbc:ID>
    <cbc:Percent>19</cbc:Percent>
    <cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
  </cac:TaxCategory>
</cac:AllowanceCharge>
```

### Invalid XML
```
<cac:AllowanceCharge>
  <cbc:ChargeIndicator>false</cbc:ChargeIndicator>
  <cbc:Amount currencyID="EUR">20.00</cbc:Amount>
</cac:AllowanceCharge>
```

## Affected Fields

- [BT-95 Document level allowance VAT category code](/resources/xrechnung/bt-95-document-level-allowance-vat-category-code)

## Related Rules

- [BR-31](/resources/kosit-validator-errors/br-31-document-allowance-amount-required)
- [BR-33](/resources/kosit-validator-errors/br-33-document-allowance-reason-required)

## Validation Tools

- [Official KoSIT Validator](https://github.com/itplr-kosit/validator): Run the official KoSIT validator with the XRechnung configuration to check EN 16931 and XRechnung rules.
- [Convert PDF to XRechnung](/pdf-to-xrechnung): Find validation errors during conversion and review each correction.

## Related Resources

- [Official Specification](https://docs.peppol.eu/poacc/billing/3.0/rules/ubl-tc434/)
- [Test Suite](https://github.com/itplr-kosit/xrechnung-testsuite)
- [All validation errors](/resources/kosit-validator-errors): Overview of the EN 16931, XRechnung and Peppol validation rules explained here.
