Skip to main content
Glama

Split PDF

split_pdf

Split a PDF into multiple new PDF files by page ranges or every N pages, returning saved paths. Use when you need several output files; original PDF remains unchanged.

Instructions

Split one PDF into several new PDFs: one file per page range, or one every N pages. Use this when you want several output files; for a single file of chosen pages use extract_pdf_pages. Returns the list of saved paths. The input is not changed; give the password for an encrypted 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": {
      "file": "<file>"
    },
    "name": "split_pdf"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileYesPath to the file (absolute, or relative to the working directory).
everyNoSplit every N pages instead of using ranges.
rangesNoOne file per range, e.g. ["1-3", "4-9", "10-"].
passwordNoThe PDF's current password, if it has one.
output_dirNoFolder for the parts. Defaults to the input’s folder.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Goes beyond the annotations by stating the input PDF is left unchanged and that the tool returns a list of saved paths, plus the password requirement for encrypted files. With annotations already declaring non-destructive/non-readonly, this adds real context, though it is silent on what happens if output paths already exist (overwrite vs. error).

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?

Four short sentences, front-loaded with what the tool does, then the alternative, then the return value and safety note. No filler.

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

Completeness5/5

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

With no output schema, the description still describes the return value (list of saved paths), covers the non-mutating behavior and the encrypted-PDF case. Everything needed to invoke it correctly is present.

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 the schema already documents file, every, ranges, password and output_dir. The description reinforces the ranges/every distinction and the password case, but adds no format or default detail beyond what the schema provides.

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?

States a specific verb and resource ("Split one PDF into several new PDFs") and enumerates the two output modes (per page range, or every N pages). An agent can distinguish it from extract_pdf_pages and merge_pdf from the text alone.

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

Usage Guidelines5/5

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

Explicitly names the alternative: "Use this when you want several output files; for a single file of chosen pages use extract_pdf_pages." Both the when-to-use and when-not-to-use conditions are stated with the selecting sibling.

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