Skip to main content
Glama

Update a page

update_page
DestructiveIdempotent

Replace a Folio Wiki page's entire Markdown body, optionally using baseRevision to prevent overwriting concurrent edits. If the page changed, the write is refused with a revision conflict.

Instructions

Replaces a document page's WHOLE body markdown; it is not a merge. Pass baseRevision (the bodyRevision read_page returned) to protect against a stale read: if the page changed since, nothing is written and the call fails with revision_conflict and the current revision; read the page again, apply the change to the current text and retry. Without baseRevision the write is unconditional and replaces anything typed into the page after you read it (the replaced text is kept in a backup). Underline is written ++text++, never <ins>/<u>. Does NOT support data tables — a table has no single body to replace; use folio_table_insert/folio_table_update/folio_table_add_column instead. Requires a write-scoped token. In a space set to review mode the page is NOT changed: the answer is status 'proposed' with a proposalId, the new text applies when an editor accepts it, and you must not repeat the call (a new call replaces your open proposal).

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": {
      "id": "<id>",
      "markdown": "<markdown>"
    },
    "name": "update_page"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesPage id
markdownYesNew body markdown (the whole page)
baseRevisionNoThe bodyRevision from read_page. If the page has changed since, the write is refused with revision_conflict. Omit for an unconditional replace

Output Schema

NameRequiredDescriptionDefault
idNoPage id
iconNoEmoji icon, if the page has one
kindNoPage kind: doc, board, table, form, base, canvas, artifact, pdf or office
pathNoPath relative to the space root
coverNoCover image URL, if the page has one
orderNoPosition among its siblings
spaceNoSpace slug the page belongs to
titleNoPage title
statusNoPage status
messageNoReview mode only: what happened and what to do next
updatedAtNoLast change, ISO timestamp
proposalIdNoReview mode only: id of the proposal that was queued instead of writing the page

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already declare destructive=true and idempotent=true, but the description adds substantial behavior beyond them: replaced text is kept in a backup, a stale write is refused with `revision_conflict` plus the current revision, a write-scoped token is required, and in review mode the page is unchanged and a proposalId is returned. It also warns that an unconditional replace can overwrite text typed after the read, which is exactly the risk an agent needs to weigh before setting destructive=true in motion.

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?

Front-loads the replace-not-merge semantics, then layers revision safety, unconditional-write risk, syntax rules, table exclusion, auth, and review mode. Though long, nearly every clause carries operational information an agent would otherwise have to discover by failing a call.

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 destructive, revision-sensitive write with a small schema, the description covers the mutation model, concurrency protection, auth requirement, unsupported content type with named alternatives, and the review-mode outcome. An output schema exists, so the absence of return-value detail is not a gap.

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; the description still adds value by tying `baseRevision` to the `bodyRevision` returned by read_page and spelling out the conflict-and-retry workflow, and by stressing that `markdown` is the whole page rather than a patch. It stops short of describing any format or size constraints on the markdown payload.

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 ('Replaces a document page's WHOLE body markdown') and immediately distinguishes the operation from a merge. It also rules out a sibling class explicitly ('Does NOT support data tables ... use folio_table_insert/folio_table_update/folio_table_add_column instead'), so an agent can route correctly without opening another 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?

Gives explicit conditional guidance: pass `baseRevision` to protect against a stale read, omit it for an unconditional replace, and use the folio_table_* tools for tables. It also describes the recovery path on `revision_conflict` (re-read, re-apply, retry) and the review-mode path (expect status 'proposed', do not repeat the call).

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