Reference
Markdown exportBR-AG-01 IPSI category requires a matching VAT breakdown
An Invoice that contains an Invoice line (BG-25), a Document level allowance (BG-20) or a Document level charge (BG-21) where the VAT category code (BT-151, BT-95 or BT-102) is "IPSI" shall contain in the VAT breakdown (BG-23) at least one VAT category code (BT-118) equal with "IPSI".
Problem Description
ERROR
EN 16931 rule for IGIC/IPSI (Canary Islands, Ceuta, Melilla)
Context and Significance
The IPSI VAT category (code "M", the indirect tax of Ceuta and Melilla) comes from the updated EN16931 code lists supported by the current XRechnung 3.0.2 rulepack; this rule keeps every IPSI line reconcilable against a matching VAT breakdown.
Solution
Add a cac:TaxTotal/cac:TaxSubtotal (BG-23) whose cac:TaxCategory/cbc:ID is "M" (IPSI) so the breakdown mirrors the IPSI lines, allowances or charges.
Quick actions
Valid Examples
- Invoice line with category "M" (IPSI) at 10.00 % and a BG-23 breakdown group with BT-118 = "M"
Invalid Examples
- An invoice line uses category "M" (IPSI) but the only BG-23 breakdown group carries BT-118 = "S"
Code Examples
<cac:InvoiceLine>
<cac:Item>
<cac:ClassifiedTaxCategory>
<cbc:ID>M</cbc:ID>
<cbc:Percent>10.00</cbc:Percent>
<cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
</cac:ClassifiedTaxCategory>
</cac:Item>
</cac:InvoiceLine>
<cac:TaxTotal>
<cac:TaxSubtotal>
<cac:TaxCategory>
<cbc:ID>M</cbc:ID>
<cbc:Percent>10.00</cbc:Percent>
<cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
</cac:TaxCategory>
</cac:TaxSubtotal>
</cac:TaxTotal><cac:InvoiceLine>
<cac:Item>
<cac:ClassifiedTaxCategory>
<cbc:ID>M</cbc:ID>
<cbc:Percent>10.00</cbc:Percent>
<cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
</cac:ClassifiedTaxCategory>
</cac:Item>
</cac:InvoiceLine>
<cac:TaxTotal>
<cac:TaxSubtotal>
<cac:TaxCategory>
<cbc:ID>S</cbc:ID>
<cbc:Percent>19.00</cbc:Percent>
<cac:TaxScheme><cbc:ID>VAT</cbc:ID></cac:TaxScheme>
</cac:TaxCategory>
</cac:TaxSubtotal>
</cac:TaxTotal>