Permitted tax exemption reason code

Error FX-SCH-A-001065 Factur-X

Value of 'ram:ExemptionReasonCode' is not allowed.

Mandatory rule: As long as it is violated, the invoice is invalid and will be rejected by validators.
What is wrong

The value in ram:ExemptionReasonCode is not empty and does not appear in the Factur-X code list defined for this field.

What the rule means

The code identifies the reason for a tax exemption. A value that is not permitted cannot be interpreted as one of the defined exemption reasons.

Please use a permitted tax exemption reason code

The value in ram:ExemptionReasonCode is not included in the applicable code list. You can check and adjust the code using that list.

What to do
  1. Check the value of ram:ExemptionReasonCode in the tax information for the invoice line’s net price.
  2. Use a value from the Factur-X code list defined for this field; under this rule, an empty value is also permitted.
  3. Generate the invoice again and validate it once more.
Technical details

The test accepts an empty value or a value present in the enumeration for code list 25 in FACTUR-X_EXTENDED_codedb.xml.

Where the rule applies

The rule applies to ram:ExemptionReasonCode in the tax information for an item’s net price on an invoice line.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:IncludedSupplyChainTradeLineItem/ ram:SpecifiedLineTradeAgreement/ram:NetPriceProductTradePrice/ram:IncludedTradeTax/ ram:ExemptionReasonCode
Test expression (assert/@test)
string-length($codeValue25)=0 or document('FACTUR-X_EXTENDED_codedb.xml')/codedb/cl[@id=25]/enumeration[@value=$codeValue25]