Skip to main content
Glama

Render invoice PDF

invoice_pdf

Render a stored invoice into an A4 PDF file for sending, returning the saved file path.

Instructions

Call this tool to render a stored invoice as an A4 PDF you can send. Returns the path of the file written.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
numberYesInvoice number to render, as returned by invoice_create
out_pathNoWhere to write the PDF; defaults to <data dir>/pdf/<number>.pdf. The page carries the issuer block, the BILL TO client block, dates, an item table with wrapped descriptions, subtotal, discount, one tax line per rate, the total, payment details and notes, and every money value on it carries its currency code. Use a .pdf path: the bytes written are always PDF

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.20.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses the key side effect (writing a PDF file) and the return value (the path of the file written), which is important behavioral information. It does not mention overwrite behavior or error cases, but for this simple rendering tool the core behavior is transparent.

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?

The description is two short sentences with no filler. The primary purpose is front-loaded in the first sentence, and the second adds the essential return-value detail. Every sentence earns its place.

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 simple two-parameter tool with no output schema, the description plus schema covers purpose, output format, parameter meanings, and return value. It could additionally mention what happens when the invoice number is invalid, but that is not essential for an agent to invoke the tool correctly in the common case.

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 the input schema already documents both parameters thoroughly, including the default out_path and the guarantee that bytes written are PDF. The free-text description adds no parameter semantics beyond what the schema covers, matching the baseline.

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?

The description uses a specific verb ('render') with a clear resource ('a stored invoice') and output format ('an A4 PDF'), and states the return value. It is not a tautology and clearly identifies the tool's function, though it does not explicitly contrast with sibling pdf_* tools.

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 opening phrase 'Call this tool to render a stored invoice' gives a clear context for when to use it. It does not name alternatives or provide when-not-to-use exclusions, so it stops short of a 5, but the usage intent is unambiguous.

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