Rule reference

BR-DE-25-a The payment means type code (BT-81) is "59" (SEPA direct debit), so exactly one DIRECT DEBIT group (BG-19) must be present

The payment means type code (BT-81) is "59" (SEPA direct debit), so exactly one DIRECT DEBIT group (BG-19) must be present. BG-19 carries the mandate reference (BT-89), the bank assigned creditor identifier (BT-90, required by BR-DE-30) and the debited account (BT-91, required by BR-DE-31). Those three are what a collection is matched against: without them the buyer's bank cannot tell whether the debit you are about to raise is one they have authorised, and the mandate is what makes the collection lawful rather than merely expected.

This rule is implemented and its error payload below is real, but the long-form write-up — normative text, worked example, divergence note — is not written yet. Everything the library knows about this rule is on this page. Ask and we will prioritise it.

Business term
BG-19
Severity
fatal

What the library returns

The exact object in result.errors when this rule fires. Generated by running @attestwire/en16931, not transcribed:

TeachingError
{
  "rule": "BR-DE-25-a",
  "field": "BG-19",
  "severity": "fatal",
  "message": "The payment means type code (BT-81) is \"59\" (SEPA direct debit), so exactly one DIRECT DEBIT group (BG-19) must be present. BG-19 carries the mandate reference (BT-89), the bank assigned creditor identifier (BT-90, required by BR-DE-30) and the debited account (BT-91, required by BR-DE-31). Those three are what a collection is matched against: without them the buyer's bank cannot tell whether the debit you are about to raise is one they have authorised, and the mandate is what makes the collection lawful rather than merely expected.",
  "fix": "Set payment.directDebit with mandateReference (BT-89), creditorIdentifier (BT-90, your SEPA Gläubiger-ID) and debitedAccount (BT-91, the payer's IBAN). If you are asking to be paid rather than collecting, use payment.meansCode \"58\" with payment.iban instead — that is what most invoices want even when a mandate exists, since the mandate governs the collection rather than the invoice.",
  "example": "\"payment\": { \"meansCode\": \"59\", \"directDebit\": { \"mandateReference\": \"MANDAT-2026-01\", \"creditorIdentifier\": \"DE98ZZZ09999999999\", \"debitedAccount\": \"DE98700500001234567890\" } }",
  "xpath": "/ubl:Invoice/cac:PaymentMeans/cac:PaymentMandate",
  "docsUrl": "https://attestwire.com/rules/BR-DE-25-a"
}

xpath locates the element in the generated UBL document, which is where a KoSIT or Peppol validator will report the same problem.

A passing value

the shape this field expects
"payment": { "meansCode": "59", "directDebit": { "mandateReference": "MANDAT-2026-01", "creditorIdentifier": "DE98ZZZ09999999999", "debitedAccount": "DE98700500001234567890" } }

The fix

Set payment.directDebit with mandateReference (BT-89), creditorIdentifier (BT-90, your SEPA Gläubiger-ID) and debitedAccount (BT-91, the payer's IBAN). If you are asking to be paid rather than collecting, use payment.meansCode "58" with payment.iban instead — that is what most invoices want even when a mandate exists, since the mandate governs the collection rather than the invoice.

Arrived from a stack trace? The docsUrl on every error links straight here. Something wrong on this page — tell us.