Skip to main content
Glama

Huddle

save_draft

Idempotent

Save the document's shared draft without publishing it. Use it to keep work in progress; it replaces the draft everyone sees. Returns the new draft_version to send with the next save, or a conflict when the draft has changed since the version you name.

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>",
      "body": "<body>",
      "expect_draft_version": "<expect_draft_version>"
    },
    "name": "save_draft"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesthe document id, from list_docs or search_docs
bodyYesthe whole text of the draft, at most 20000 characters
expect_draft_versionYesthe draft_version from get_doc or from your last save

Output Schema

NameRequiredDescriptionDefault
idYesThe document id.
has_draftYesWhether a draft is now open.
draft_differsYesWhether it differs from the published body.
draft_versionYesThe version acknowledged by this mutation.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Goes well beyond the annotations (which only declare non-read-only, closed-world, idempotent) by disclosing that the save overwrites the draft everyone sees and that expect_draft_version drives optimistic concurrency, returning a new draft_version or a conflict. That is exactly the behavioral context an agent needs before mutating shared state.

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?

Two tight sentences, front-loaded with the core action and scope, then the concurrency contract. No filler, and every clause carries operational information.

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 shared-state mutation with three required parameters, the definition covers overwrite semantics, the versioning contract, and the failure mode (conflict). An output schema exists, so the brief mention of the returned draft_version is bonus rather than an obligation.

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 real meaning the schema does not: expect_draft_version is explained as the version you name to detect concurrent changes, and the returned draft_version is framed as the value to send on the next save. This documents the read-modify-write loop rather than restating field descriptions.

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 ("Save the document's shared draft") plus an explicit scope boundary ("without publishing it"), which cleanly separates it from publish_draft and discard_draft. An agent can identify the operation 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 it to keep work in progress" gives a clear when-to-use condition and the "without publishing" clause implicitly excludes the publish path. It stops short of naming publish_draft or discard_draft as the alternatives for those other intents, so the routing is clear but not fully explicit.

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