Skip to main content
Glama

discard_draft

Destructive

Remove unpublished draft changes for a locale so the working version reverts to the published content. Live site stays unchanged; cannot be recovered; use trash_content for never-published content.

Instructions

Throw away the unpublished draft changes of one locale, so the working version falls back to the published one. The live site is unchanged; the discarded draft cannot be recovered. Refused for content that was never published (there is nothing to fall back to) — use trash_content to remove that instead.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteNoSite slug or id to act in (multisite). Omit to use this server's default site. Call list_sites to see what exists — an empty tree or search usually means the wrong site, not missing content.
localeNoLocale code. Omit for the document's own locale (its site-default variant, else its only variant).
documentIdYesThe item's documentId (stable across locales and versions), e.g. from tree, list_pages or get_content.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.1.3
    • changedInput schema / properties / documentId / description
      Previous value: -"Content documentId"New value: +"The item's documentId (stable across locales and versions), e.g. from tree, list_pages or get_content."
  2. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true and idempotentHint=false, but the description adds real context beyond them: the live site is unchanged, the discarded draft is unrecoverable, the document falls back to the published version, and the operation is refused for never-published content. The only minor gap is it doesn't describe the failure/response shape, but the behavioral profile is well disclosed.

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 tightly written sentences, front-loaded with the core action, then the side-effect/irreversibility, then the refusal condition and alternative. Every sentence earns its place.

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 mutation with no output schema, the description supplies the fallback semantics, irreversibility, scope (one locale), and the negative case routing, all on top of annotations that cover the safety profile. Nothing an agent needs to call it correctly is missing.

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% and each parameter (site, locale, documentId) is fully documented in the schema itself. The description only alludes to the locale parameter scope; it adds no syntax or format detail beyond the schema, so the 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 (throw away), a precise resource (unpublished draft changes of one locale), and the resulting state (working version falls back to published). It also names the sibling it is not for, so an agent can distinguish it from trash_content without opening a 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?

Explicitly covers when to use it (discard draft changes for a locale), the exclusion condition (refused for content that was never published), and the alternative to use instead (trash_content). Nothing about selection 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.