cvc-pattern-valid:Value does not match the regex pattern declared in the schema
Fix: Read the failing pattern and value out of the validator message; apply a deterministic transformation (trim, upper-case, pad, strip prefix) where one is safe, otherwise the caller must supply the corrected identifier. Provide the required value in the free validator.
cvc-pattern-valid is an XSD facet-validation error raised when an element or attribute value fails the xsd:pattern regular expression declared on its simple type. The canonical message reads: "Value 'X' is not facet-valid with respect to pattern 'P' for type 'T'." In EN 16931 invoice payloads it usually fires on identifier fields (BT-30 Seller legal registration ID, BT-46 Buyer identifier, BT-90 Bank assigned creditor identifier), date fields with a stricter UN/CEFACT format pattern, and country-CIUS extensions like the Italian fattura tax-ID pattern.
Engine Classification
Business data required · Explicit input workflow · No assumptions made
What is cvc-pattern-valid?
cvc-pattern-valid is a fatal validation rule defined in the xsd specification.
When this rule fires, the invoice is rejected by Peppol access points and never reaches the buyer.
Why This Error Matters
xsd:pattern facets are the parser-level guard for identifiers and structured strings. A pattern failure short-circuits Schematron, so a single malformed Seller registration ID or Endpoint ID stops the entire invoice from being processed by the receiver.
cvc-pattern-valid is a hard failure — the invoice must be corrected and re-sent before it can reach the recipient.
Validator Behavior
- ·Causes invoice rejection
- ·Error returned: cvc-pattern-valid
- ·Specification: xsd
Before / After
<cbc:EndpointID schemeID="0088">123 456 789 01</cbc:EndpointID>
<cbc:EndpointID schemeID="0088">1234567890123</cbc:EndpointID>
Technical Reference
Seeing this in production? The API handles cvc-pattern-valid automatically. See the fix response →
Frequently Asked Questions
The validator message echoes both the value and the pattern. Search the published XSD for the type name in the message (for example AgencyIDType, EndpointID); the xsd:pattern facet is the regex you must match.
Sometimes. Trimming whitespace, padding leading zeros, and uppercasing alpha characters are safe transformations that Invoice Navigator applies automatically. Substantive ID changes (wrong Leitweg-ID, wrong VAT number) are not auto-fixed because the consequences are tax or routing.
Stricter CIUS layers add country-specific patterns on top of EN 16931. A SIRET value that passes the generic Peppol BIS XSD will still fail Chorus Pro's stricter regex. Always run against the country CIUS your buyer uses.
BT-30 Seller legal registration identifier, BT-46/BT-47 Buyer identifier, BT-90 Bank assigned creditor reference, BT-12/BT-13 references when a country CIUS adds a pattern, and dates emitted as UN/CEFACT format 102 instead of 616.
No. xsd:pattern runs at the parser level, before Schematron. The structural failure short-circuits validation. Catch it earlier by validating against the XSD in your CI pipeline rather than waiting for the Access Point to reject.
Related Content
Last updated: 5 May 2026
Validate your invoice
Drop your XML here to check for cvc-pattern-valid
Fix cvc-pattern-valid with guided input
Upload your invoice and we'll ask for the missing data, then apply a safe, auditable fix.