Skip to main content
Glama

Invoiceer e-invoicing tools

Read a PDF invoice

read_invoice_pdf
Read-only

Read an ordinary (non-e-invoice) PDF invoice and return its data in the input format of create_einvoice: seller and buyer (name, address, VAT ID, country), invoice number, dates, IBAN/BIC, Leitweg-ID and the invoice lines (only if quantity x price and the line sum match the PDF's net total; otherwise one line with the net total). Regex-based, no guessing: fields we can't read reliably are missing and listed in missing. Check and complete them, then call create_einvoice to get XRechnung, ZUGFeRD or Peppol. Scanned PDFs (no text layer) are not supported. Pass the PDF base64-encoded in file_base64. Max 5 MB.

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": {
      "file_base64": "<file_base64>"
    },
    "name": "read_invoice_pdf"
  }
}

Input Schema

NameRequiredDescriptionDefault
file_base64YesThe PDF invoice, base64-encoded.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

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

Goes well past readOnlyHint/openWorldHint: discloses the regex-based extraction strategy, that unreadable fields are omitted and reported in `missing` rather than guessed, the exact condition for emitting invoice lines, and a 5 MB size cap. These are invocation-relevant traits the annotations cannot express.

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?

Front-loaded with purpose and scope; every clause carries information (scope, returned fields, line-extraction rule, remediation step, limits). The mid-sentence field enumeration is dense and could be compressed, but there is no filler.

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?

No output schema exists, and the description compensates by describing the return shape and the `missing` list, including the fallback behavior when line extraction fails. Combined with the size/encoding limits, an agent has everything needed to call it and handle the result.

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% and there is only one parameter, so the baseline is already high; the description adds encoding ('base64-encoded in `file_base64`') and the 5 MB maximum, which the schema does not state. Minor overlap with the schema's own description keeps it from a 5.

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?

States a specific verb and resource ('read a PDF invoice') and immediately bounds the scope to ordinary, non-e-invoice PDFs, which distinguishes it from the e-invoice siblings like validate_einvoice/create_einvoice. It also enumerates the returned fields, so an agent knows the shape of the result before calling.

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

Usage Guidelines5/5

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

Gives an explicit when-to-use (ordinary PDF needing conversion) and when-not (scanned PDFs with no text layer are unsupported), plus the follow-on step: inspect `missing`, complete fields, then call create_einvoice. The alternative path is named rather than implied.

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