Exactly one ram:ID in the tax registration

Error FX-SCH-A-000903 Factur-X

Element 'ram:ID' 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:ID does not occur exactly once in ram:SpecifiedTaxRegistration. The element is either missing or occurs more than once.

What the rule means

ram:ID contains the tax registration identifier. Exactly one identifier element must be present for this tax registration.

Please provide exactly one `ram:ID` for the tax registration

ram:ID is missing from ram:SpecifiedTaxRegistration of ram:InvoicerTradeParty or occurs more than once. You can correct the number of identifier elements.

What to do
  1. Locate ram:SpecifiedTaxRegistration within ram:InvoicerTradeParty.
  2. Make sure it contains exactly one ram:ID.
  3. Generate the invoice again and validate it once more.
What it looks like
✗ Triggers the message
<ram:SpecifiedTaxRegistration/>
✓ Correct
<ram:SpecifiedTaxRegistration>
  <ram:ID>x</ram:ID>
</ram:SpecifiedTaxRegistration>
Technical details

The rule counts the direct ram:ID elements in ram:SpecifiedTaxRegistration and requires the count to be exactly one.

Where the rule applies

The rule applies to ram:SpecifiedTaxRegistration of ram:InvoicerTradeParty.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeSettlement/ ram:InvoicerTradeParty/ram:SpecifiedTaxRegistration
Test expression (assert/@test)
count(ram:ID)=1