Provide exactly one telephone number

Error FX-SCH-A-001095 Factur-X

Element 'ram:CompleteNumber' 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

The element ram:TelephoneUniversalCommunication does not contain exactly one ram:CompleteNumber. It is either missing or occurs more than once.

What the rule means

The contact’s telephone number for the delivery address is provided through ram:CompleteNumber. Exactly one value is required.

Please provide exactly one telephone number for the contact

For the delivery address, the contact’s telephone communication does not contain exactly one ram:CompleteNumber. You can adjust this in the XML.

What to do
  1. Locate ram:CompleteNumber under ram:TelephoneUniversalCommunication.
  2. Make sure exactly one ram:CompleteNumber is present.
  3. Generate the invoice again and validate it once more.
What it looks like
✗ Triggers the message
<ram:TelephoneUniversalCommunication/>
✓ Correct
<ram:TelephoneUniversalCommunication>
  <ram:CompleteNumber>+33123456789</ram:CompleteNumber>
</ram:TelephoneUniversalCommunication>
Technical details

The XPath condition checks whether the number of child elements named ram:CompleteNumber is exactly one.

Where the rule applies

The rule applies to the telephone communication of the contact under ShipToTradeParty for an invoice line.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:IncludedSupplyChainTradeLineItem/ ram:SpecifiedLineTradeDelivery/ram:ShipToTradeParty/ram:DefinedTradeContact/ ram:TelephoneUniversalCommunication
Test expression (assert/@test)
count(ram:CompleteNumber)=1