Skip to main content
Glama

Pages: set body

pages_set_body
Destructive

Replace the entire body text of a .pages document, which resets body formatting. Preview the change on a throwaway copy with dry_run=true before overwriting the file.

Instructions

Replace the entire body text of a .pages document (needs Pages + GUI session). Body formatting is reset. dry_run=true previews the change on a copy without touching the file. Use only to replace the entire body text; it resets body formatting, so warn the user. Prefer pages_replace_all or pages_fill_placeholders.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyYesThe new body text; paragraphs separated by newlines. Resets body formatting.
pathYesPath to the .pages document (absolute, or starting with ~).
dry_runNotrue = make the change on a throwaway copy, run every check, and return what would change; the file itself is not touched. Use it before broad or risky edits and show the user.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv2.4.1
    • addedInput schema / properties / body / description
      Added value: +"The new body text; paragraphs separated by newlines. Resets body formatting."
    • addedInput schema / properties / dry_run / description
      Added value: +"true = make the change on a throwaway copy, run every check, and return what would change; the file itself is not touched. Use it before broad or risky edits and show the user."
    • addedInput schema / properties / path / description
      Added value: +"Path to the .pages document (absolute, or starting with ~)."
  2. First observedv2.4.0

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, so the mutation profile is known. The description adds genuine context beyond that: the GUI-session/Pages prerequisite, the specific loss ('Body formatting is reset'), and the dry_run preview semantics. It stops short of stating reversibility or backup behavior, which keeps it at 4 rather than 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The destructive warning is front-loaded, which is good, but the same fact is stated three times ('Body formatting is reset', 'it resets body formatting', schema-level 'Resets body formatting') and the opening sentence is restated by 'Use only to replace the entire body text'. Meaningful trimming is possible.

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?

The tool has an output schema and full schema coverage, so return values and params need no prose. The description supplies the environment prerequisite, the destructive consequence, and the safe-preview route, which is close to sufficient. Minor gaps remain around backup/restore availability (siblings exist for it) and confirmation expectations.

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%, so path, body, and dry_run are all documented in the schema itself. The description's remarks about body formatting and dry_run largely repeat the schema text rather than adding syntax or constraints. Baseline 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?

States a specific verb and resource ('Replace the entire body text of a .pages document') with explicit scope ('entire body'). It also names the two sibling tools it is not (pages_replace_all, pages_fill_placeholders), so an agent can distinguish it without opening any schema.

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?

Explicit when-to-use ('Use only to replace the entire body text'), when-not (implies partial edits, routed elsewhere), and named alternatives ('Prefer pages_replace_all or pages_fill_placeholders'). Nothing is left to inference.

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