Skip to main content
Glama
cmendezs

mcp-einvoicing-be

by cmendezs

validate_invoice_be

Validate UBL 2.1 XML invoices against Belgian business rules for Peppol BIS 3, PINT-EU, or Mercurius profiles. Checks EN16931 base rules and overlay rules, returning structured per-rule errors and warnings to ensure compliance.

Instructions

Validate a UBL 2.1 XML invoice against Belgian business rules.

For 'peppol-bis-3'/'pint-eu': checks the CEN EN16931 base rules (structural + arithmetic/totals, ~50 BR-* rules) via a compiled Schematron. Does NOT check the Peppol-specific overlay (profile ID registration, EndpointID scheme, narrowed code lists) — the result's metadata.scope is "en16931-base-only", and a warning is included. This is not a full Peppol BIS3 conformance check; a document that passes may still be rejected by a real Peppol Access Point. See context-library/decisions/peppol-schematron-artifact.md for why. For 'mercurius': applies the Mercurius-specific overlay rules only (endpoint scheme, PO reference) — also not full EN16931/Peppol base compliance. Returns a structured result with per-rule error and warning messages.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xmlYesRaw UBL 2.1 XML invoice content
profileNoValidation profile: 'peppol-bis-3' (default), 'pint-eu', or 'mercurius'peppol-bis-3

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full transparency responsibility and does so excellently. It discloses exactly what is checked (~50 BR-* rules), what is NOT checked (Peppol overlay, profile ID, EndpointID, narrowed code lists), the resulting metadata.scope, the warning behavior, and the risk of Peppol Access Point rejection. It also explains that mercurius only applies overlay rules, not full compliance.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long, but the length is justified by the complex tool behavior and the need to disclose significant limitations. The opening sentence provides a clear summary, and subsequent paragraphs are structured by profile. Slightly verbose, but every section contributes critical information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity, two parameters, an output schema, and no annotations, the description is comprehensive. It explains the validation scope, per-profile behavior, return structure, and references a design decision document. It covers both what the tool does and what it intentionally omits, making it complete for an agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already describes both parameters. The description adds meaningful value by explaining what each profile actually does in behavioral terms: peppol-bis-3/pint-eu run EN16931 base rules, while mercurius runs only overlay rules. This goes beyond the enum labels and default value in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb ('Validate') and resource ('UBL 2.1 XML invoice against Belgian business rules'), then immediately clarifies what is covered per profile. It clearly distinguishes itself from sibling tools like generate_invoice_be, parse_ubl_invoice_be, and transform_to_ubl, and explicitly states the scope limitations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives clear context for when the tool is appropriate: it covers EN16931 base rules for peppol-bis-3/pint-eu and Mercurius overlay rules for mercurius. It also states when it is NOT sufficient (not a full Peppol BIS3 conformance check). It does not explicitly name alternative tools to use for full conformance, but the profile-level guidance is strong.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cmendezs/mcp-einvoicing-be'

If you have feedback or need assistance with the MCP directory API, please join our Discord server