Skip to main content
Glama

Watermark PDF

watermark_pdf

Apply a grey diagonal text watermark to every page of a PDF and save the result as a new copy, leaving the original unchanged.

Instructions

Save a copy of a PDF with a grey diagonal text watermark (like "DRAFT" or "CONFIDENTIAL") on every page. Latin letters only here; other scripts return an error pointing to the website. Returns the saved path; the input is not changed.

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>",
      "text": "<text>"
    },
    "name": "watermark_pdf"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileYesPath to the file (absolute, or relative to the working directory).
textYesThe watermark text.
outputNoWhere to save the result. Defaults to a new file next to the input.
opacityNo0.05 (faint) to 1 (solid). Default 0.2.

Output Schema

NameRequiredDescriptionDefault
notesYesAnything the output does not carry over from the input.
summaryYesOne line describing the result.
writtenYesPaths of the files written, in order.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.1.2

TDQS

A4.2/5.0
Behavior4/5

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

Annotations declare a non-destructive, closed-world write; the description adds genuinely new behavior beyond them: the input file is left untouched, the result is saved as a copy, the watermark is rendered diagonally in grey across all pages, and unsupported scripts produce a specific error. It does not say what happens if the output path already exists (overwrite vs. fail), which is the main remaining behavioral unknown.

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?

Three sentences, front-loaded with the core action and effect, followed by the one input restriction and the output contract. No sentence repeats the schema or the annotations and nothing is padding.

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 4-parameter, non-destructive write tool with a full schema and an output schema, the description covers purpose, input restriction, non-mutation guarantee, and error path. Only overwrite behavior for an existing output path is left unstated, a small gap given the structured fields already 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 every parameter including the default output location and opacity range is already documented in the schema. The description adds only indirect meaning (that the text renders grey and diagonal, i.e., a non-configurable style), so the baseline of 3 applies.

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 states a specific verb and resource: save a copy of a PDF with a grey diagonal text watermark on every page. The visual style and scope ('every page') are concrete enough that an agent can distinguish this from every other PDF sibling operation without opening the schema.

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 clear usage constraint: Latin letters only, with non-Latin scripts returning an error that points to the website. It also clarifies the copy semantics ('the input is not changed'). There is no explicit when-to-use-versus-alternative routing, but no sibling performs watermarking, so this is only a minor gap.

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