Skip to main content
Glama
xrechnung-mcp

xrechnung-mcp

by Ozycore

extract_zugferd

Extracts embedded Factur-X XML from a ZUGFeRD PDF using base64-encoded PDF data, returning XML as UTF-8 or an empty string when none is found.

Instructions

Extract the embedded Factur-X XML from a ZUGFeRD PDF. Input is the PDF content as a base64-encoded string. Returns the embedded XML as a UTF-8 string, or an empty string if no XML is found.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "pdfBase64": "<pdfBase64>"
    },
    "name": "extract_zugferd"
  }
}

Input Schema

NameRequiredDescriptionDefault
pdfBase64YesBase64-encoded ZUGFeRD (Factur-X) PDF bytes. Whitespace in the base64 string is tolerated.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses the return type (UTF-8 string) and the important edge case that a PDF without embedded XML yields an empty string rather than an error. It omits what happens on malformed base64 or a non-PDF payload, which is the remaining behavioral gap.

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?

Three short sentences, front-loaded with the action and resource, then input format, then return value. Nothing is redundant and every sentence contributes.

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

Completeness4/5

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

For a single-parameter tool with no output schema, the description covers input format and return semantics including the empty-string case, which is what an agent most needs. Only the failure mode for invalid input is left unaddressed.

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 coverage is 100% and there is only one parameter, so the schema already documents pdfBase64 including the whitespace-tolerance note. The description restates that the input is base64 PDF content but adds no format or constraint detail beyond the schema, making the baseline 3 appropriate.

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

Purpose4/5

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

States a specific verb and resource: extracting embedded Factur-X XML from a ZUGFeRD PDF, and names the exact output (the raw embedded XML). It does not explicitly differentiate itself from siblings like parse_invoice or validate_xrechnung, so it falls short of a 5, but the resource and product are unambiguous.

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

Usage Guidelines3/5

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

Usage is only implied: the description makes clear you use it when you want the raw embedded XML rather than a parsed or validated result, but it never states when to prefer this over parse_invoice or validate_xrechnung. No exclusions or prerequisites are given.

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

Deploy Server

Other Tools