Skip to main content
Glama

Undo a change

undo_change
Destructive

Undo block or container changes made via WorldAPI by agents, panels, or tokens; list recent changes when no ID is given. Confirm before reverting another user's edits.

Instructions

Take back a change made through WorldAPI: blocks set or filled and containers edited, by this agent, the panel, or another token. Without id, it lists recent changes instead, newest first, with who made them, where, and how many blocks. Blocks that changed again since, by players or a later change, stay as they are unless force is on. Changes made by players in the game, by physics, and to entities aren't kept, and the list empties when the server stops. Confirm with the user before undoing someone else's change.

Input Schema

NameRequiredDescriptionDefault
idNoThe change to undo; leave out to list them
forceNoAlso restore blocks changed again since
limitNoHow many items to return; 0 answers only the total, to count without listing
worldNoWhen listing: only this world
cursorNo`nextCursor` from the previous page

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv4.2.0

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the destructiveHint annotation, the description explains important behavioral limits: later changes are preserved unless force is used, certain changes are never recorded, and the change list expires when the server stops. It also warns about undoing another user's change, which is valuable context for a destructive operation.

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?

The description is front-loaded with the core action and then adds mode, limitation, and safety details in a compact paragraph. Every sentence contributes necessary information for a destructive undo tool.

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?

The description is strong for a five-parameter destructive tool with no output schema: it explains listing output fields and retention limits. It could say a bit more about the result of an actual undo, but the core decision and invocation details are present.

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 schema already documents all five parameters. The description adds useful meaning by explaining that omitting id switches to listing mode and that force overrides the default preservation of blocks changed again since.

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?

The description states a specific verb and resource: taking back a change made through WorldAPI, covering blocks and containers. It also clearly distinguishes the two modes: with an id it undoes, and without an id it lists recent changes. This lets an agent distinguish it from sibling tools such as set_blocks.

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?

The description explicitly explains when to pass an id versus when to omit it for listing. It also gives the important usage caution to confirm with the user before undoing someone else's change and clarifies that player-made, physics, and entity changes are not tracked.

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