Invalid payment code

Error FX-SCH-A-000527 Factur-X

Value of 'ram:TypeCode' 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:TypeCode is not included in the code list specified for this field. An empty value does not trigger this error according to the test condition.

What the rule means

The code identifies the payment means used. A code not in the list does not assign the payment information to a category provided by the code list.

Please use an allowed code for the payment means

The ram:TypeCode for the payment means is not included in the specified code list. You can correct the entry by using a value allowed in that list.

What to do
  1. Locate the document-level payment means information and check ram:TypeCode.
  2. Replace the disallowed value with one included in the specified code list.
  3. Regenerate the invoice and validate it again.
Technical details

The test accepts an empty code or a value from code list 18 of the Factur-X code database.

Where the rule applies

The rule applies to ram:TypeCode in the document-level payment means information.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeSettlement/ ram:SpecifiedTradeSettlementPaymentMeans/ram:TypeCode
Test expression (assert/@test)
string-length($codeValue18)=0 or document('FACTUR-X_BASIC_codedb.xml')/codedb/cl[@id=18]/enumeration[@value=$codeValue18]