Skip to main content
Glama

set_tool_option

Set a control value on a Dungeondraft tool by item, index, metadata, color, pressed state, or slider number when no typed control tool exists; verify IDs and types with list_tool_controls first.

Instructions

Set a value on a Dungeondraft tool's control.

Pass exactly one of:
  item          text of an entry in an OptionButton or ItemList, by its
                visible name
  item_index    that entry's POSITION instead. Texture selectors and
                FloorShapeTool's SmartTileId have blank labels, so they
                cannot be named by text at all
  item_metadata substring of an entry's metadata. A texture menu item holds
                its ASSET PATH there, so this picks a texture by path —
                which is usually what you actually mean
  color         '#rrggbb' for a colour picker. Some colour controls wrap the
                picker in a container; this reaches through it
  pressed       true/false for a toggle, e.g. 'Bevel', 'Shadow'
  value         a number for a slider

Call list_tool_controls first — control ids and types vary per tool, and the
value kind must match the control.

This is the DIAGNOSTIC surface, for controls with no typed tool of their
own. Where a typed tool exists, use it: it validates, reads its result back
and is undoable, none of which this is.

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": {
      "tool": "<tool>",
      "control": "<control>"
    },
    "name": "set_tool_option"
  }
}

Input Schema

NameRequiredDescriptionDefault
itemNo
toolYes
colorNo
valueNo
controlYes
pressedNo
item_indexNo
item_metadataNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.5.0

TDQS

A4.5/5.0
Behavior4/5

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

With no annotations, the description carries the burden and does real work: it discloses that this path does not validate, does not read results back, and is not undoable, which is exactly the risk profile an agent needs before mutating state. It stops short of saying what a failed set returns or whether a bad value is silently ignored.

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?

Front-loaded one-line purpose, then a scannable indented enumeration of the value kinds, then the prerequisite and the fallback caveat. Long but every block is load-bearing; minor tightening is possible in the parenthetical asides.

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?

For an 8-parameter mutation tool with no annotations and no output schema, the definition covers purpose, value-kind selection, ordering with list_tool_controls, and behavioral limits versus typed tools. What is missing is failure behavior (unknown control id, mismatched value kind) and any indication of what, if anything, comes back.

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 0%, so the description must compensate, and it largely does: six of the eight parameters get semantics plus gotchas (blank labels on texture selectors and SmartTileId force item_index; texture metadata holds the asset path; colour pickers may be wrapped in a container). It also imposes the mutual-exclusion rule ('Pass exactly one of') that the schema does not encode. Only 'tool' and 'control' are left unstated beyond the list_tool_controls hint.

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 ('Set a value on a Dungeondraft tool's control') and immediately frames it as the generic/diagnostic fallback rather than one of the typed setters in the sibling list. An agent can tell it apart from set_tool_layer, set_grid, set_map_style, etc., without opening any 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 an explicit prerequisite ('Call list_tool_controls first — control ids and types vary per tool') and an explicit when-not ('Where a typed tool exists, use it'). The condition that routes the agent to alternatives is stated, along with why those alternatives are preferred.

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

Deploy Server

Other Tools