All rules · en16931 · error
BR-CL-01
The document type code must come from the UNCL1001 code list subset that Peppol permits.
Reviewed
Why this rule exists
The type code determines how the receiver processes the document. A code outside the permitted subset has no agreed meaning between the two parties.
Why it usually happens
- Using an internal document-type code rather than the UNCL1001 value
- Emitting 381 (credit note) on a UBL Invoice element
How to fix it
Map your internal document types to UNCL1001 codes in one place, and fail loudly on an unmapped type.
<cbc:InvoiceTypeCode>999</cbc:InvoiceTypeCode>
<cbc:InvoiceTypeCode>380</cbc:InvoiceTypeCode>
The official rule
The document type code MUST be coded by the invoice and credit note related code lists of UNTDID 1001.
Verbatim from the published artefact. We execute the official Schematron unmodified, so this is exactly what an Access Point checks.
Schematron test
(self::cbc:InvoiceTypeCode and ((not(contains(normalize-space(.), ' ')) and contains(' 71 80 81 82 84 102 130 202 203 204 211 218 219 295 325 326 331 380 382 383 384 385 386 387 388 389 390 393 394 395 456 457 471 472 473 500 501 527 553 575 623 633 751 780 817 870 875 876 877 935 ', concat(' ', normalize-space(.), ' '))))) or (self::cbc:CreditNoteTypeCode and ((not(contains(normalize-space(.), ' ')) and contains(' 81 83 261 262 296 308 381 396 420 458 502 503 532 ', concat(' ', normalize-space(.), ' ')))))Applied to nodes matching cbc:InvoiceTypeCode | cbc:CreditNoteTypeCode
Rule-pack versions
| Rule-pack | Layer | Severity | Applies to |
|---|---|---|---|
| pint-eu-1.1.1 | en16931 | error | billing/creditnote, billing/invoice |
Related rules
Check your own invoice
Paste your XML and see every rule that fires, not just this one. Free, no sign-up, and we never store the document.
Open the validator