Skip to main content
Glama

set_page

Replace one page's content in a local .drawio file with new mxGraphModel XML while leaving other pages untouched and preserving that page's compression; use list_pages/get_page first.

Instructions

Replaces the content of one page (diagram) in a local .drawio file with new mxGraphModel XML, leaving every other page in the file untouched. Compression of the replaced page matches whatever that page's original compression state was. Use list_pages/get_page first to find the target page.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageYesWhich page to replace: a zero-based page index (e.g. "0"), the page's exact name, or the page's id as shown by list_pages.
pathYesAbsolute or relative path to the local file. Must end in .drawio or .xml.
contentYesThe new page content as plain mxGraphModel XML (uncompressed). Must be a single <mxGraphModel> element without any <diagram> tags.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/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 disclose the two behaviors that matter most for a destructive write: the blast radius is limited to one page, and compression state is preserved to match the page's original encoding. That is genuine information beyond the schema. It omits failure/error behavior (missing path, file absent, malformed XML) and whether the operation is reversible, which keeps it out of 5 territory.

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 tight sentences, front-loaded with the operation and its scope, followed by the compression guarantee and the discovery prerequisite. Nothing is repeated from annotations or schema descriptions and no sentence is filler.

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 three-required-parameter local file mutation with no output schema, the description covers the essential agent-facing facts: what is changed, what is preserved, and how to locate the target. It does not say whether the call reports success or how errors surface, which is a modest gap rather than a blocking one.

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 all three parameters are already fully documented, including the accepted identifier forms for 'page' and the 'no <diagram> tags' constraint on 'content'. The description only restates that content is mxGraphModel XML, adding no syntax or edge-case semantics beyond the schema; 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 - replacing the content of exactly one page (diagram) in a local .drawio file - and immediately bounds the scope with 'leaving every other page in the file untouched.' An agent can distinguish this from read-oriented siblings like get_page and list_pages 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?

'Use list_pages/get_page first to find the target page' names the prerequisite tools and the intended workflow order, which is exactly the routing knowledge an agent lacks otherwise. It stops short of stating when not to use this tool (e.g. creating a new page vs. editing an existing one), so it falls just below the explicit when/when-not bar.

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