Skip to main content
Glama
SaloQT

imgui-mcp

by SaloQT

imgui_import_json

Restore a Dear ImGui UI layout by importing it from a JSON object or file. Clears the current layout and recreates all windows and widgets exactly as originally exported.

Instructions

Import a UI layout from JSON (same format as imgui_export_json). Clears the current layout and recreates all windows and widgets.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
jsonNoThe layout JSON object to import (same format as export_json output).
pathNoPath to a JSON file to import. Use this OR the 'json' field.
Behavior3/5

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

With no annotations provided, the description carries the burden of behavioral disclosure and does state the key destructive behavior: 'Clears the current layout and recreates all windows and widgets.' This is a meaningful disclosure of the wipe-and-replace behavior. However, it doesn't disclose whether there's an undo/redo hook, whether the import is atomic (partial failures), or how it interacts with the undo stack vs. imgui_load_snapshot.

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 sentences, zero wasted words. Front-loads the purpose in the first sentence and adds the critical destructive behavior in the second. Appropriate length for a tool with a simple purpose and clear parameters.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is moderately complex (nested objects, destructive operation, mutating state) but has no output schema and no annotations. The description covers the destructive behavior and format reference, which is good. However, it could benefit from noting whether this integrates with the undo stack (there are imgui_undo/imgui_redo siblings) and whether the two input methods (json object vs path) have any precedence or merge behavior. For a destructive operation that recreates an entire layout, slightly more behavioral context would help.

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 coverage is 100% and both parameters are well-documented in the schema. The description notes the 'same format as export_json output' which adds practical context, but both fields (json, path) are already clear from the schema. The either-or relationship between the two params is stated in the schema ('Use this OR the json field'). The description adds marginal value beyond the schema in this dimension.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb+resource ('Import a UI layout from JSON') and clearly references the sibling export tool format. It distinguishes from imgui_export_json indirectly. However, it doesn't explicitly distinguish from imgui_load_snapshot, which could be a competing alternative for restoring UI state.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description notes the format matches imgui_export_json, which provides some correlation context. It mentions the destructive side effect ('Clears the current layout'), giving implicit guidance that this is a full replacement operation, not a merge. However, it doesn't explicitly contrast with imgui_load_snapshot or explain when to prefer one over the other.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/SaloQT/imgui-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server