Skip to main content
Glama

merge_pdfs

Combine two or more PDF documents from base64 data or public URLs into one unified vector PDF, preserving input order and allowing a custom output filename.

Instructions

Merges two or more PDF documents (supplied as base64 strings or public URLs) into a single unified vector PDF.

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": {
      "pdfs": "<pdfs>"
    },
    "name": "merge_pdfs"
  }
}

Input Schema

NameRequiredDescriptionDefault
pdfsYesArray of at least 2 PDF inputs (base64 data URI or public http/https URLs) to merge in order
output_filenameNoFilename for the merged document (default: "merged.pdf")merged.pdf

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.4.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations at all, the description carries the full behavioral burden; it does add useful context by stating accepted input encodings (base64 strings or public URLs) and that the output is a flattened 'unified vector PDF'. However, it is silent on size/page limits, remote fetch failures, whether page order is preserved, and whether an existing output_filename is overwritten.

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 well-formed sentence that front-loads the operation and then the input forms and result type. No filler, no repetition of the tool name.

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 two-parameter tool with fully documented schema and no output schema, the description covers inputs, output nature, and minimum arity. Agent-critical operational details such as remote URL fetch behavior and size limits are absent, but the definition is otherwise sufficient to call correctly.

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%, and the schema already explains that pdfs is an array of at least 2 base64/http inputs merged in order and that output_filename defaults to 'merged.pdf'. The description adds no format or ordering detail beyond that, so the 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 ('merges two or more PDF documents ... into a single unified vector PDF') and names the accepted input forms, so an agent can immediately tell this apart from split_pdf or compress_pdf. It stops short of explicitly naming the sibling it replaces, but the operation is unambiguous.

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?

The description says what it does but never says when to choose it over alternatives like split_pdf or manage_pdf_lifecycle, nor any prerequisite or exclusion (e.g., mixed page sizes, encrypted inputs). Usage must be inferred entirely from the verb.

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