Skip to main content
Glama

Render template to PDF

render_template

Fill a saved template with data and return the PDF. Each successful render counts as one document. Re-sending the same data with the same idempotency key returns the same PDF and is not counted again. Text that does not fit its box, an item that covers text and an item past the page edge come back as warnings; the PDF is made all the same.

Input Schema

NameRequiredDescriptionDefault
csvNoCSV text for each table source, keyed by the source name. The first row names the columns.
dataNoThe field values. Each data path of the template reads one value from here.
templateYesThe template's id or its name, as list_templates gives them.
idempotency_keyNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.7/5.0
Behavior4/5

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

Annotations only say readOnlyHint=false and destructiveHint=false, i.e. a non-destructive write. The description adds substantive behaviour the annotations cannot convey: each successful render is metered as one document, replaying the same data with the same idempotency key returns the same PDF without a second charge, and layout problems surface as warnings while the PDF is still produced. This is real operational context (billing, idempotency, non-fatal failure mode). It stops short of covering authorisation/scoping, size limits or what happens when the template id is unknown.

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?

Four short sentences, purpose front-loaded, then metering/idempotency, then the warning behaviour — a sensible order with no filler. The final sentence packs three distinct warning conditions into one clause, which is dense but still parseable. Slightly more structure (or an explicit clause on return shape) would improve scanability.

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

Completeness3/5

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

There is no output schema, so the description carries the burden of describing the return value; it says 'return the PDF' and mentions warnings, but never indicates how the PDF is delivered or how warnings are surfaced in the response. Combined with no differentiation from render_pdf, an agent lacks the information to choose confidently between the two render paths. Metering and idempotency, the hardest behaviours to guess, are well covered.

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 75%, so the schema already documents template, data and csv reasonably well, which sets a baseline of 3. The description earns an extra point by explaining the *effect* of idempotency_key (same key + same data yields the same PDF and is not re-counted), which the bare maxLength=256 constraint does not convey. It does not add further syntax detail for data paths or CSV source keys.

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 opens with a specific verb+resource+result: fill a saved template with data and return the PDF. That is unambiguous about what the tool does. It does not, however, name or contrast itself with the close sibling render_pdf (or preview_template), so an agent must infer the division of labour from sibling names alone.

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?

The description implies when this tool is appropriate (you have a saved template with data/CSV and want the final PDF) and it clarifies retry semantics via the idempotency key. But it never states when to prefer it over preview_template or render_pdf, which are the obvious alternatives in the sibling list. Usage guidance is present but inferential rather than explicit.

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