Skip to main content
Glama

E-Invoice Space

Validate e-invoice

validate_invoice
Read-onlyIdempotent

Validate one e-invoice and return the verdict valid, the per-stage summary, the format (container, syntax, profile), the problems as findings (German titles, official rule texts, affected EN 16931 business terms) and the extracted invoice data invoice. Pass an XML invoice as xml (plain text), a PDF (ZUGFeRD, Factur-X) or any file as file_base64. Max. 30 MB. Takes about 1 to 10 seconds and counts against the monthly quota.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "validate_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
xmlNoThe invoice XML (XRechnung, CII, UBL) as text. Use either this or `file_base64`.
strictNoCount a KoSIT reject even when only warnings are behind it (those warnings become errors). Recommended for invoices to public authorities.
filenameNoOptional file name, shown in the result.
file_base64NoThe invoice file, base64-encoded - required for PDF (ZUGFeRD, Factur-X). Use either this or `xml`.
include_invoice_dataNo`false` leaves out the extracted invoice data `invoice`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already cover read-only, idempotent, non-destructive and closed-world, so the description's added value is the cost and latency profile: 30 MB ceiling, 1–10 second runtime, and consumption of the monthly quota. That quota/limit disclosure is genuinely useful for an agent planning calls, though it does not mention rate limiting behavior or what happens on oversized input.

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

Conciseness5/5

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

Front-loads the action and the returned fields, then packs input forms and limits into two tight sentences with no filler. Every clause carries information an agent needs before calling.

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?

With no output schema, the description fully carries the burden of describing return values and does so field by field. Combined with input-form guidance, size limit, latency and quota cost, an agent has everything needed to call this correctly.

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

Parameters3/5

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

Schema description coverage is 100%, so all five parameters are already documented, including the xml-vs-file_base64 exclusivity and the strict-mode behavior. The description echoes the xml/file_base64 choice and PDF requirement but adds no new meaning, and never mentions `filename` or `include_invoice_data`; baseline 3 applies.

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?

Names a specific verb and resource ("Validate one e-invoice") and immediately enumerates the shape of the result (verdict, summary, format, findings, invoice). An agent can tell this is a single-invoice validation call and not the usage/quota sibling without opening any schema.

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?

Clearly states how to supply input: XML as text in `xml`, PDF (ZUGFeRD, Factur-X) or any file via `file_base64`. It also gives the operational envelope (max 30 MB, 1–10 seconds, quota impact). What is missing is any when-not-to-use or routing advice, though the only sibling (get_usage) makes that largely moot.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources