Skip to main content
Glama

fill_pdf_form

Populate interactive PDF forms (AcroForms) with text, numbers, or checkbox values, with optional flattening to lock completed fields.

Instructions

Fills interactive PDF forms (AcroForms) with text, numbers, or checkboxes, with optional form flattening.

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": {
      "pdf": "<pdf>",
      "fields": "<fields>"
    },
    "name": "fill_pdf_form"
  }
}

Input Schema

NameRequiredDescriptionDefault
pdfYesInteractive PDF document as a base64 data URI or public http/https URL
fieldsYesKey-value map of form field names to their values (e.g. {"client_name": "Acme", "agreed": true})
flattenNoWhether to flatten form fields to prevent further editing (default: true)
output_filenameNoOutput filename (default: "filled_form.pdf")filled_form.pdf

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.4.0

TDQS

B3.3/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the burden. It discloses the meaningful behavioral detail that flatten=true removes further editability (the schema default), and implies a write/produce operation returning a new file. It does not state what happens to unfilled or unknown field names, whether values are validated, or output format/return shape.

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?

A single front-loaded sentence with the core action and the notable optional behavior (flattening). No filler, no repetition of schema fields.

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?

Adequate but thin for a mutation tool with no annotations and no output schema. Key operational facts an agent would want — that field names must match existing AcroForm fields, behavior on unknown fields, and what the result is (a file reference vs. inline data) — are absent, though the fully documented schema covers inputs.

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%, so all four parameters are already documented, including the flatten default and the fields map example. The description only echoes the accepted value types (text, numbers, checkboxes) and the flattening option; it adds no syntax or naming guidance beyond the schema. Baseline 3 applies.

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: fills interactive PDF forms (AcroForms) with text, numbers, or checkboxes, plus optional flattening. This distinguishes it from siblings like compress_pdf, render_pdf, or stamp_pdf, though it never names an alternative or clarifies overlap with render_pdf/stamp_pdf.

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

Usage Guidelines2/5

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

No when-to-use or when-not-to-use guidance. The word 'interactive' hints that non-interactive PDFs are out of scope, but nothing routes the agent between this and siblings such as stamp_pdf or render_pdf, and no prerequisites (e.g., that the PDF must actually contain AcroForm fields) are stated.

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