Skip to main content
Glama

generate_document

Create a DOCX or PDF document by merging a template with key-value data. Receives a signed download URL. Uses credits: 1 for DOCX, 2 for PDF.

Instructions

Generate a single document from a template and data. Returns a signed download URL. Costs 1 credit (DOCX) or 2 credits (PDF).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
templateIdYesTemplate UUID
dataYesKey-value data to fill into the template. Keys must match template variables.
outputFormatNoOutput format: docx (1 credit) or pdf (2 credits)docx
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses the credit cost and output format options, and that a signed download URL is returned. It does not mention idempotency, expiration, or failure modes, but the provided information is sufficient for basic understanding.

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?

Two sentences, no wasted words. The core purpose is front-loaded first, followed by specifics. Every sentence contributes essential information.

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 tool with 3 parameters and no output schema, the description covers purpose, output type, and cost. It does not explain edge cases like missing template variables or retry behavior, but it is sufficiently complete for typical usage.

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 description coverage is 100%, so each parameter has a description. The description adds context about credits and the signed URL, which enhances understanding beyond the schema. The cost-per-format detail is particularly useful for the outputFormat parameter.

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?

The description clearly states the action (generate), the resource (single document from template and data), and the outcome (returns signed download URL). It effectively distinguishes from siblings like generate_batch by specifying 'single document'.

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 notes the credit cost per format, which aids in cost-aware selection, but does not explicitly state when to use this tool versus alternatives like generate_batch or check_credits. It implies usage for single document generation without providing exclusions or prerequisites.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ayo-nci/bulkrender-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server