Use an allowed value for schemeID

Error FX-SCH-A-000685 Factur-X

Value of '@schemeID' 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 non-empty value of the schemeID attribute is not included in the code list used by this rule. An empty attribute value passes this specific check.

What the rule means

schemeID identifies the identification scheme used for the legal organization’s identifier. Any value provided must match the code list used by this rule.

Please use an allowed scheme value for `schemeID`

The non-empty value of schemeID on ram:ID is not in the code list used by this rule. You can update the value or leave it empty.

What to do
  1. Check schemeID on the ram:ID element in ram:SpecifiedLegalOrganization.
  2. Use a value from the code list for schemeID, or leave the attribute value empty.
  3. Generate the invoice again and validate it.
Technical details

The non-empty value of @schemeID is checked against entries in code list 12 in FACTUR-X_EXTENDED_codedb.xml; the test allows an empty value.

Where the rule applies

The rule applies to the schemeID attribute of the ram:ID element in the buyer’s tax representative’s ram:SpecifiedLegalOrganization.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ ram:BuyerTaxRepresentativeTradeParty/ram:SpecifiedLegalOrganization/ram:ID
Test expression (assert/@test)
string-length($codeValue12)=0 or document('FACTUR-X_EXTENDED_codedb.xml')/codedb/cl[@id=12]/enumeration[@value=$codeValue12]