Skip to main content
Glama
formfeed

formfeed

Official

Split a PDF

split_pdf

Split a PDF into parts by page count or custom page ranges, returning a ZIP of the parts or a single PDF when only one part results.

Instructions

Cuts a PDF into parts, every N pages each or one part per entry of ranges, and returns the render with download_url: a ZIP of the parts, named after the source (contract-1.pdf, contract-2.pdf and so on), or the PDF itself when there is one part. get_pdf_info gives the page count first. Pass exactly one PDF: source, a render or library file of the workspace; path, a file on this machine; or file_base64. Starter plan and above; 0.5 units on a live key. A PDF/A or a password-protected PDF is refused.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "split_pdf"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathNoAbsolute path of a PDF on this machine, up to 100 MB; sent with the request and not kept
everyNoPages per part; give every or ranges
rangesNoOne part per entry, each a page selection such as 1-3,5, or 4- for page 4 to the last; give every or ranges
sourceNoA PDF of the workspace: the rnd_ id of a PDF render, or a PDF of the file library by name (such as terms.pdf) or fil_ id
filenameNoName of the file behind download_url; the source's name when left out
file_nameNoName of the PDF given as file_base64 or path, e.g. contract.pdf; the results are named after it
file_base64NoThe PDF itself, base64 encoded, up to 20 MB; sent with the request and not kept

Output Schema

NameRequiredDescriptionDefault
idYesrnd_ id of the render
formNoWhat fill_pdf_form did: the fields filled, those left out (unknown name or invalid value) and those whose calculation or display format no viewer ran
pdfaNoThe PDF/A verdict (PDF/A-2b or PDF/A-3b), when the template declares it
errorYesWhy a failed render failed
unitsYesUnits the render counted
outputNoThe format of the file: pdf, png, jpg, webp, docx or pptx, or zip for the several files of split_pdf and pdf_to_image
statusYes
einvoiceNoThe e-invoice report, when the render made one
templateYesThe template and version rendered; null for html and conversions
expires_atYesWhen download_url stops working; get_render issues a fresh one
page_countYes
environmentYes
download_urlYesSigned link to the file; null until the render succeeded
accessibilityNoThe PDF/UA-1 verdict, when the template declares it

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.3.26

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations it discloses the return shape (a ZIP of parts named after the source, or the PDF itself for one part), plan gating ("Starter plan and above"), cost ("0.5 units on a live key"), input limits, and the refusal conditions for PDF/A and password-protected files. It also notes that path and file_base64 content is "sent with the request and not kept", which annotations alone never convey.

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?

The action and its two modes are front-loaded, followed by return format, prerequisites, cost, and refusals in a compact block. It is dense and slightly run-on, but nearly every clause carries operational information.

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?

For a non-destructive split tool with an output schema, this covers everything an agent needs: input modes, part-naming, size limits, plan/cost requirements, and the two refusal cases. Nothing material is left for the caller to guess.

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 100%, so the baseline is 3, but the description adds a meaning the schema does not state: exactly one of source, path, or file_base64 must be supplied. It also reinforces the naming relationship between filename/file_name and the produced parts.

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 names a specific verb and resource ("Cuts a PDF into parts") and immediately states the two splitting modes, every-N-pages or one part per range entry. That is enough to tell it apart from siblings like get_pdf_info, compress_pdf, and pdf_to_image.

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

Usage Guidelines4/5

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

It gives a concrete prerequisite ("get_pdf_info gives the page count first") and an exclusivity rule ("Pass exactly one PDF" across source, path, or file_base64), which is real when-to-use guidance. It stops short of naming alternative tools for overlapping goals, so there is no explicit when-not-to-use comparison.

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