W System / EU e-invoice API: validate, create and route EN 16931 invoices
EU e-invoice API: validate, create and route EN 16931 invoices
Short answer: Send the invoice to POST https://api.wsystem.dev/einvoice/validate as the raw body (XML or a ZUGFeRD/Factur-X PDF). You get valid plus every error with its official rule ID (e.g. BR-CO-10), a plain-English message, the XPath and a fix hint. To produce an invoice, post simple JSON to /einvoice/create; to find out whether a customer is on Peppol and what their country requires, call GET /einvoice/route?id=BE0403170701.
Key facts
- Rule sets: CEN EN 16931 validation artefacts (UBL and CII) and the KoSIT XRechnung 3.0.2 configuration (release 2026-08-31), run unmodified, plus the UBL 2.1 / CII D16B XML schemas.
- Inputs: UBL Invoice and CreditNote, UN/CEFACT CII, and PDFs with an embedded factur-x.xml / zugferd-invoice.xml / xrechnung.xml. Profile detected automatically (EN 16931, XRechnung, Peppol BIS, Factur-X).
- Not checked yet: Peppol BIS 3 specific rules (PEPPOL-EN16931-*). Every response says exactly which rule sets ran (
checked). - Create: formats en16931, xrechnung and peppol-bis3 (UBL 2.1 structure); line totals, VAT breakdown per category and rate, exemption codes (VATEX) for reverse charge, intra-EU and export are computed, and the result is validated before it is returned. Example body: /einvoice/sample.
- Route lookup: VIES VAT status, Peppol Directory registration and BIS 3 invoice support, the B2B mandate for the country (BE, FR, DE, PL, IT, RO, HR, GR, ES, HU; dated and linked to the official source) and a recommended format. The French PPF directory is not included yet.
- Due-diligence report:
POST /ddreportbundles VAT, business register, sanctions, EORI, GLEIF LEI and Peppol into one JSON report with risk flags, a score and a UTC timestamp ($0.49). - MCP tools: validate_einvoice, create_einvoice, einvoice_route, due_diligence_report at https://api.wsystem.dev/mcp/.
- Licences and sources: CEN EN 16931 validation artefacts, EUPL-1.2, github.com/ConnectingEurope/eInvoicing-EN16931; KoSIT XRechnung configuration, Apache-2.0, github.com/itplr-kosit/validator-configuration-xrechnung. Both are used unmodified.
- A technically valid file is not tax advice. We are a validator, not a Peppol Access Point: we do not send invoices.
Examples
Validate a ZUGFeRD / Factur-X PDF
curl -X POST https://api.wsystem.dev/einvoice/validate \
-H 'Content-Type: application/pdf' --data-binary @invoice.pdfValidate an XRechnung XML (force XRechnung rules)
curl -X POST 'https://api.wsystem.dev/einvoice/validate?rules=xrechnung' \
-H 'Content-Type: application/xml' --data-binary @xrechnung.xmlCreate an XRechnung from JSON
curl -s https://api.wsystem.dev/einvoice/sample > invoice.json
curl -X POST https://api.wsystem.dev/einvoice/create \
-H 'Content-Type: application/json' --data @invoice.jsonCan I e-invoice this company?
curl 'https://api.wsystem.dev/einvoice/route?id=BE0403170701'Pricing
| Channel | Price |
|---|---|
| Free tier | 20 calls/day per IP across all endpoints, no key |
| x402 POST /einvoice/validate | $0.03 USDC per invoice |
| x402 POST /einvoice/create | $0.08 USDC per invoice |
| x402 GET /einvoice/route | $0.02 USDC per lookup |
| x402 POST /ddreport | $0.49 USDC per report |
Questions and answers
Which errors do I get back?
Each failed rule with its official ID (BR-xx, BR-CO-xx, BR-DE-xx, XSD), severity, a plain-English message, the XPath location, the business terms (BT-xx) involved and, for common rules, how to fix it.
Does it check Peppol BIS 3?
Not yet. Peppol BIS 3 invoices are checked against EN 16931 (the core every Peppol invoice must meet), and the response marks PeppolBIS3 as not checked. Peppol-specific rules will be added once licensing is confirmed with OpenPeppol.
Is ZUGFeRD MINIMUM or BASIC WL accepted?
They are parsed, but the response notes that these profiles are not EN 16931 compliant invoices on their own for German or French B2B.
Do you store my invoices?
No. Invoices are processed in memory and not stored; only per-IP call counters are kept for the free tier.
Which rule versions do you use?
CEN EN 16931 artefacts as shipped in the KoSIT XRechnung configuration 3.0.2 (release 2026-08-31). We update when KoSIT and CEN publish new releases.
Related
- One-call KYB check for EU companies
- EU VAT number validation API (VIES)
- MCP server for EU VAT, EORI, company registry and sanctions
- API reference (OpenAPI)
Facts and competitor details checked 2026-10-17. W System Hungary Kft. is the maker of this product. Not affiliated with the European Commission. Not legal or tax advice.