Skip to main content
Glama

Discard the staged draft

discard_draft
DestructiveIdempotent

Drops the project's staged conversation draft — the free and paid edits accumulated on the current cut and not committed yet — so the next edit starts from the cut again. The committed versions and the cut are untouched, and the thread records the discard. Answers discarded (false when nothing was staged) and changes (how many staged edits were dropped). Requires write. $0.

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": {
      "project_id": "<project_id>"
    },
    "name": "discard_draft"
  }
}

Input Schema

NameRequiredDescriptionDefault
project_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already flag destructive=true, idempotent=true, readOnly=false, but the description adds substantial value beyond them: exactly what is destroyed (staged free and paid edits), what survives (committed versions, the cut), that the thread records the discard, the required `write` scope, the $0 cost, and the returned `discarded`/`changes` fields absent an output schema.

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?

Two sentences, front-loaded with the action and its scope, followed by the side-effect guarantees and return values. The em-dash parenthetical is long but carries definitional weight; nothing is filler.

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 one-parameter mutation with no output schema, the description covers destruction scope, preserved state, audit trail, permission requirement, cost, and both return fields. An agent has everything needed to call it correctly and safely.

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?

Only one parameter (project_id) and schema description coverage is 0%, so the description needs to compensate. It does so only obliquely via 'the project's staged conversation draft,' which implies project scoping but never states the parameter's role or format.

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?

Specific verb (drops) plus a precisely defined resource (the project's staged conversation draft), scoped further as 'free and paid edits accumulated on the current cut and not committed yet.' This distinguishes it cleanly from siblings such as commit or cancel without opening either 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?

The description establishes clear context for use: it discards only uncommitted staged edits, and 'the committed versions and the cut are untouched' implicitly warns that this is not the tool for reverting committed work. It stops short of naming an explicit alternative (e.g., commit) for the keep-the-edits case.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources