Check the IBAN for SEPA payment type 58

Warning BR-DE-19 XRechnung

"Payment account identifier" (BT-84) should contain a valid IBAN if SEPA is required as the payment means with code 58 in "Payment means type code" (BT-81).

Recommendation: The invoice remains valid but should be corrected so that it can be processed automatically.
What is wrong

When ram:TypeCode has the value 58, ram:PayeePartyCreditorFinancialAccount/ram:IBANID does not contain an IBAN that passes the IBAN check. The rule explicitly checks BT-84 in this case.

What the rule means

Payment type code 58 denotes a SEPA payment. For this payment type, the payment account identifier BT-84 must contain a valid IBAN.

Affected fields BT-84 BT-81
Please provide a valid payee IBAN for SEPA payment type 58

No valid payee IBAN was recognized for payment type 58. You can correct the account identifier in the payment details.

What to do
  1. Check whether ram:TypeCode contains the value 58.
  2. Provide the payee’s valid IBAN in ram:PayeePartyCreditorFinancialAccount/ram:IBANID.
  3. Check the value through BankAccount.IBAN.
  4. Generate the invoice again and validate it once more.
What it looks like
✗ Triggers the message
<ram:SpecifiedTradeSettlementPaymentMeans>
  <ram:TypeCode>58</ram:TypeCode>
  <ram:PayeePartyCreditorFinancialAccount>
    <ram:IBANID>123</ram:IBANID>
  </ram:PayeePartyCreditorFinancialAccount>
</ram:SpecifiedTradeSettlementPaymentMeans>
✓ Correct
<ram:SpecifiedTradeSettlementPaymentMeans>
  <ram:TypeCode>58</ram:TypeCode>
  <ram:PayeePartyCreditorFinancialAccount>
    <ram:IBANID>DE89370400440532013000</ram:IBANID>
  </ram:PayeePartyCreditorFinancialAccount>
</ram:SpecifiedTradeSettlementPaymentMeans>
Check in FactoorSharp
  • BankAccount.IBAN (BT-84)
  • PaymentMeans.TypeCode (SpecifiedPaymentMeans: BT-81)
  • FacturXInvoice.PaymentMeans (ID: BT-81)
Technical details

The test passes other payment type codes. When ram:TypeCode equals 58, the ram:IBANID of the payee’s creditor account is passed to xr:checkIBAN.

Where the rule applies

The rule applies to document-level ram:SpecifiedTradeSettlementPaymentMeans when ram:TypeCode has the value 58.

Original message from the Schematron
"Payment account identifier" (BT-84) soll eine korrekte IBAN enthalten, wenn in "Payment means type code" (BT-81) mit dem Code 58 SEPA als Zahlungsmittel gefordert wird.
Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeSettlement/ ram:SpecifiedTradeSettlementPaymentMeans[normalize-space(ram:TypeCode) = ('30','58')]
Test expression (assert/@test)
not(normalize-space(ram:TypeCode) = '58') or xr:checkIBAN(string(ram:PayeePartyCreditorFinancialAccount/ram:IBANID))