Skip to main content
Glama

Edit a wiki page (patch for small changes)

wiki_edit_page

Modify an existing wiki page by appending content, replacing a section or body, or applying precise patch edits with exact text matching. Add or remove tags, sources, summary, and type values.

Instructions

SMALL EDITS: USE mode="patch" with edits=[{old_text:"exact existing text",new_text:"replacement"}]; omit content and section. Each old_text must match the body exactly once; edits run in order and all must succeed before saving. mode="append" adds content; "replace_section" replaces a section (give section); "replace_all" replaces the body. summary/type replace values; sources/tags are added (replace_all replaces sources); remove_sources deletes entries.

Input Schema

NameRequiredDescriptionDefault
modeYes"append", "replace_section", "replace_all" or "patch" (small edits).
tagsNoTags to add (optional).
typeNoNew page type (optional): source, entity, concept, comparison, synthesis, overview.
editsNoRequired for patch only: 1–100 edits, applied in order. Invalid edits save nothing.
titleYesTitle of the existing page.
contentNoMarkdown to add or replace with. Omit for patch; may be "" for metadata-only append.
sectionNoRequired for mode="replace_section": the heading text, e.g. "Early life".
sourcesNoRaw sources to add (optional).
summaryNoNew one-sentence summary (optional).
sandbox_idYesYour sandbox id from wiki_start.
remove_sourcesNoSources to remove from the list (optional), e.g. a deleted page.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses exact-match requirements, ordered edits, all-or-nothing saving, and metadata mutation semantics such as sources/tags being added and remove_sources deleting entries. It does not discuss permissions or return behavior, but the critical mutation semantics are covered.

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 description is front-loaded and dense, leading with the patch workflow before summarizing other modes. It is appropriately sized, though the long semicolon-separated sentence compresses several distinct behaviors and could be slightly easier to scan.

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 an 11-parameter mutation tool with no annotations and no output schema, the description covers the essential mode behavior, patch atomicity, and metadata semantics. It leaves some lower-priority details to the schema, but an agent has enough context to invoke it correctly.

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 meaningful mode-specific semantics beyond the schema: omit content/section for patch, provide section for replace_section, and how summary/type/sources/tags/remove_sources behave. This materially improves parameter interpretation.

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 clearly states that this tool edits an existing wiki page and explains the different edit modes, especially patch for small edits. It distinguishes the operation from read/create/delete siblings by verb and scope, though it does not explicitly name or route against those siblings.

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 clear usage direction: use mode="patch" for small edits, omit content and section in that case, and give section for replace_section. It does not explicitly state when to choose other sibling tools such as wiki_create_page or wiki_delete_page, but the mode-level guidance is strong.

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