Exactly one tax type code required

Error FX-SCH-A-000953 Factur-X

Element 'ram:TypeCode' must occur exactly 1 times.

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

ram:TypeCode is missing from ram:IncludedTradeTax or occurs more than once. It must occur exactly once in this tax block.

What the rule means

ram:TypeCode identifies the type of tax in the advance payment tax block. Exactly one such element is required by the prescribed structure.

Please provide exactly one tax type code for the advance payment

ram:TypeCode is missing from tax block ram:IncludedTradeTax or appears more than once. Exactly one such element is provided for this block.

What to do
  1. Open ram:IncludedTradeTax within the advance payment.
  2. Make sure ram:TypeCode occurs exactly once.
  3. Regenerate the invoice and check it again.
What it looks like
✗ Triggers the message
<ram:IncludedTradeTax/>
✓ Correct
<ram:IncludedTradeTax>
  <ram:TypeCode/>
</ram:IncludedTradeTax>
Technical details

The test counts ram:TypeCode elements under ram:IncludedTradeTax and requires exactly one.

Where the rule applies

The rule applies to ram:IncludedTradeTax within the advance payment.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeSettlement/ ram:SpecifiedAdvancePayment/ram:IncludedTradeTax
Test expression (assert/@test)
count(ram:TypeCode)=1