Skip to main content
Glama

Change the pages of a PDF (saved as a new PDF)

tarkle_edit_pdf

Page tools on a PDF, saved as a NEW PDF: mergeFileIds (other PDFs appended in order, up to 9), keep or remove (pages like 1-3,5; not both), order (a new page order like [3,1,2]), rotate ([{pages, degrees 90, 180 or 270}]), crop (millimetres off each side, optional pages; the cut-off part is hidden, not deleted), blankAfter and blankAtStart (blank pages), pageNumbers (true, or {position, start}), watermark (text drawn over every page; it hides nothing underneath and is NOT redaction), title, author. They apply in that order; give at least one. name sets the new file's name (default " (edited).pdf"). The file is never changed: a NEW file is saved next to it (or in folderId) and its fileId is returned; a taken name is refused (NAME_TAKEN). The same function and limits as the Tarkle chat and the API: 40 MB a PDF, a password-protected or damaged PDF is refused with the reason.

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": {
      "workspaceId": "<workspaceId>",
      "fileId": "<fileId>"
    },
    "name": "tarkle_edit_pdf"
  }
}

Input Schema

NameRequiredDescriptionDefault
cropNoMargins to cut off the pages, in millimetres. At least one side must be above 0. The cut-off part is hidden, not deleted.
keepNoWhich pages to use, as page numbers and ranges counted from the first page, for example 1-3,5,8-.
nameNoThe new file's name; the .pdf extension is added or corrected.
orderNoThe page numbers in the order the pages should appear, for example [3,1,2].
titleNoSets the title in the PDF's document properties.
authorNoSets the author in the PDF's document properties.
fileIdYesA fileId from tarkle_list_files or tarkle_list_bin.
removeNoWhich pages to use, as page numbers and ranges counted from the first page, for example 1-3,5,8-.
rotateNoRotations to apply. Each item names the pages to turn and the angle.
folderIdNoThe folder for the new file; null for the library root; omit to keep the source's folder.
llm_modelNoThe model identifier you are running as, for example "claude-opus-4-8" or "gpt-5.2". Pass "unknown" if you are not certain. Recorded for the server developer's analytics.
watermarkNoText drawn diagonally over every page. It hides nothing underneath and is not redaction.
blankAfterNoWhich pages to use, as page numbers and ranges counted from the first page, for example 1-3,5,8-.
pageNumbersNotrue adds page numbers. An object also sets where they go and the first number.
workspaceIdYesThe workspace's id from tarkle_list_workspaces.
blankAtStartNotrue: add a blank page before the first page.
mergeFileIdsNoOther PDFs to append after this one, in the order given. Each is a fileId from tarkle_list_files or tarkle_list_bin.

Output Schema

NameRequiredDescriptionDefault
fileNo
notesNo

Schema Changelog

Changes observed during successful MCP inspections.

No schema history has been recorded yet.

TDQS

A4.3/5.0
Behavior5/5

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

Against annotations (readOnly=false, destructive=false, idempotent=false), the description adds substantial non-obvious behavior: the source file is never modified, a new file is created next to it or in folderId, its fileId is returned, a taken name fails with NAME_TAKEN, and it is explicitly non-idempotent by producing a new file each time. It also clarifies that crop hides rather than deletes and that watermark is not redaction, which prevents dangerous misreads.

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 outcome and file-safety behavior are front-loaded, and each clause carries information (limits, defaults, ordering, error code). It is dense to the point of being a semi-colon chain across a long paragraph, so a reader must parse carefully, but there is little outright 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?

For a 17-parameter mutation tool with nested objects, the description covers ordering semantics, defaults, size/format limits, refusal reasons, and the non-destructive contract. Since an output schema exists, return-shape detail is correctly omitted, and nothing an agent needs to invoke it safely appears to be missing.

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 schema already defines all 17 parameters; the description still adds meaning the schema cannot express, namely the order in which operations apply, the mutual exclusion of keep and remove, the requirement to supply at least one operation, and the default naming pattern. That cross-parameter semantics is genuine added value beyond the per-field descriptions.

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?

The description names the specific resource (a PDF), the concrete operations (merge, keep/remove, order, rotate, crop, blank pages, page numbers, watermark, title/author), and the key outcome (saved as a NEW PDF). It implicitly separates itself from tarkle_edit_office_file by being explicitly PDF-only, but it never names an alternative or states that non-PDF files belong elsewhere.

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 real usage constraints: 'give at least one' operation, 'not both' for keep/remove, the default output name, and the 40 MB / password-protected / damaged file refusals. What's missing is explicit routing guidance to siblings for other file types or for in-place edits.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.