i3wm-mcp
Provides tools to query and drive a Sway (or i3) window manager session, including window focus, movement, workspace management, layout changes, application launching, and more via the i3 IPC protocol.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@i3wm-mcpmove current window to workspace 3"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
i3wm-mcp
A Model Context Protocol server for the i3 window manager (and, via the shared IPC, Sway). It lets an MCP client — Claude Code, Claude Desktop, the MCP Inspector — query and drive your i3/Sway session through a small set of well-described tools.
The tool definitions are deliberately tuned for a high
Glama tool-definition-quality score:
a consolidated, non-overlapping tool set, every parameter described, typed
output schemas, and honest readOnlyHint/destructiveHint annotations.
Derived from
caninja/i3wm-mcp(MIT). See ATTRIBUTION.md. This rewrite migrates the transport from thei3-msgCLI to the asynci3ipclibrary, consolidates 43 tools into 13, and adds tests, CI, and output schemas.
Tools
Tool | Kind | What it does |
| read | List windows from the layout tree, with filters. |
| read | Details of the currently focused window. |
| read | All active workspaces. |
| read | All display outputs (monitors). |
| read | Version + config + binding modes snapshot. |
| mutate | Focus by direction / criteria / layer / parent-child. |
| mutate | Move a container to a direction / workspace / output / scratchpad / center. |
| mutate | Switch / move-to / rename / navigate workspaces. |
| mutate | Container layout, split orientation, border style. |
| mutate | Toggle floating / fullscreen / sticky. |
| destructive | Launch a program via |
| destructive | Raw i3/Sway command escape hatch (marks, gaps, bar, reload/restart). |
| destructive | Close the focused or a matched window. |
Rarely-used verbs (marks, i3-gaps, i3bar, scratchpad show/hide, reload,
restart, and deliberately exit) are reached through run_command rather
than dedicated tools, keeping the set small and distinct.
Related MCP server: Tmux MCP Server
Requirements
A running i3 (≥4.x) or Sway session.
Python ≥ 3.10.
The server locates the i3/Sway IPC socket from the environment, so it must be
launched from within your graphical session (it needs DISPLAY, or
SWAYSOCK/I3SOCK, in its environment). Clients that spawn it from inside the
session — Claude Code, the MCP Inspector — inherit this automatically; a headless
or systemd launch would need those variables passed explicitly.
Install
git clone https://github.com/kuhyx/i3wm-mcp
cd i3wm-mcp
python -m venv .venv
./.venv/bin/python -m pip install -e ".[dev]"Run
./.venv/bin/python -m i3wm_mcp # stdio transportRegister with Claude Code
claude mcp add i3wm -- /absolute/path/to/i3wm-mcp/.venv/bin/python -m i3wm_mcpInspect the tool definitions
npx @modelcontextprotocol/inspector ./.venv/bin/python -m i3wm_mcpDevelop
./.venv/bin/python -m pytest # tests + 100% coverage gate
./.venv/bin/ruff check . && ./.venv/bin/ruff format --check .
./.venv/bin/mypy src
./.venv/bin/python scripts/rubric_check.py # local TDQS proxy checkSafety
Read tools have no side effects. Mutation tools are reversible. The three
destructive tools (exec_application, run_command, kill_window) can run
arbitrary commands, close applications, or — via run_command — restart or exit
the session; treat them accordingly and never feed them untrusted input.
License
MIT — see LICENSE.
Available Tools
12 toolsexec_applicationLaunch Application (i3 exec)ADestructive
Launch an external program via i3's exec. DESTRUCTIVE / open-world: runs an arbitrary command line on the user's machine with their privileges — never pass untrusted input. Set no_startup_id=true for programs without startup-notification support (avoids a lingering busy cursor). For built-in i3 verbs use the dedicated tools instead — focus_window, move_window, set_layout — not this.
| Name | Required | Description | Default |
|---|---|---|---|
| command | Yes | The shell command line to launch. | |
| no_startup_id | No | Pass i3's --no-startup-id flag. Default false. |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already mark as destructive and open-world. Description adds important context: 'runs an arbitrary command line on the user's machine with their privileges — never pass untrusted input.' Also explains behavior of no_startup_id flag.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences with no redundancy: purpose, warning, and usage guidance for parameter and siblings. Every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Covers all needed context given annotations (destructive, open-world), schema (100% coverage, 2 parameters), and existence of output schema. Includes security warning and sibling differentiation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% so baseline is 3. Description adds practical guidance for no_startup_id: 'Set for programs without startup-notification support (avoids a lingering busy cursor).' This adds value beyond schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states 'Launch an external program via i3's exec' with specific verb and resource, and explicitly distinguishes from sibling tools like focus_window, move_window, set_layout.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly states when to use (launching external programs), when not to use (for built-in i3 verbs), and provides security warning about untrusted input. Explains no_startup_id flag usage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
focus_windowFocus i3 WindowAIdempotent
Move keyboard focus, selected by exactly one of: a direction; a specific window (class/title/instance/mark/con_id criteria); the parent/child container; the floating/tiling layer; or an output. Reversible. Supplying none or several selectors is rejected. To move the focused window instead of focusing, use move_window.
| Name | Required | Description | Default |
|---|---|---|---|
| mark | No | Focus the window carrying this mark (criteria). | |
| layer | No | Focus the floating layer, the tiling layer, or toggle between them. | |
| title | No | Focus a window whose title matches (criteria). | |
| con_id | No | Focus the container with this exact i3 id (criteria). | |
| target | No | Focus the parent or child container of the current focus. | |
| instance | No | Focus a window whose WM_CLASS instance matches (criteria). | |
| direction | No | Focus the neighbour in this direction. | |
| window_class | No | Focus a window whose X11 class matches (criteria). |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description adds value beyond annotations by stating the tool is reversible (consistent with idempotentHint=true and destructiveHint=false) and by explaining the rejection of invalid selector combinations. However, it could briefly mention that only focus is affected, not window position.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences with no fluff: main purpose and selection options, reversibility, and important constraint/alternative. Front-loaded with key information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of 8 parameters and multiple selection methods, the description covers core behavior, constraints, and alternatives. Output schema exists, so omission of return value details is acceptable.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Although schema coverage is 100%, the description groups parameters into categories (direction, criteria, parent/child, layer, output) and clarifies mutual exclusivity, which is essential semantics not present in individual schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'Move keyboard focus' and the resource (i3 window), and distinguishes from sibling `move_window` by specifying that this tool focuses, not moves. It also explains the selection mechanism and the constraint of exactly one selector.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly names the alternative `move_window` for moving instead of focusing, and warns that supplying none or several selectors is rejected. This provides clear when-to-use and when-not-to-use guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_configInspect i3 ConfigurationARead-onlyIdempotent
Inspect i3/Sway configuration state in one call: version, whether the compositor is Sway, the loaded config path and (optionally) its full text, plus configured and active binding modes. Read-only. Set include_config_text=false to skip the potentially large config body. This is the only config-introspection tool; live layout comes from get_tree.
| Name | Required | Description | Default |
|---|---|---|---|
| include_config_text | No | Include the full config file text (can be large). Default true. |
Output Schema
| Name | Required | Description |
|---|---|---|
| is_sway | Yes | True when the running compositor identifies as Sway. |
| version | Yes | Human-readable i3/Sway version, e.g. '4.25.1'. |
| config_text | No | Full text of the loaded config, or null when not requested. |
| binding_modes | No | Names of all configured binding modes. |
| loaded_config_path | No | Path of the loaded config file, if reported. |
| active_binding_mode | No | Currently active binding mode name, or null if unsupported by the WM. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and destructiveHint. The description adds value by warning about the potentially large config body and explicitly stating 'Read-only'. No contradiction with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, front-loaded with main purpose, then details, then sibling distinction. No wasted words, every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the simple tool (one optional param, output schema exists), the description covers returned fields, parameter guidance, and sibling context. No gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with one parameter described. The description adds practical guidance on when to set include_config_text=false to skip large config body, enhancing the schema's 'can be large' note.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool inspects i3/Sway configuration state, listing specific fields (version, compositor, config path, config text, binding modes). It explicitly distinguishes itself from siblings by stating it's the only config-introspection tool and directing users to get_tree for live layout.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides explicit guidance on when to use this tool (config introspection) and when not to include config text (set include_config_text=false to skip large body). It also names the alternative get_tree for live layout, fulfilling both when-to-use and when-not-to-use.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_treeQuery i3 Layout TreeARead-onlyIdempotent
List application windows from the i3/Sway layout tree, optionally filtered by class, title, instance, role, workspace, or floating/urgent state. Read-only. Returns matched leaf windows with their ids, marks and location; use a returned id as con_id in focus_window/move_window/kill_window. For only the active window use get_focused; for a flat workspace summary use list_workspaces; for monitors use list_outputs. Capped at 200 windows (truncated flags the cap).
| Name | Required | Description | Default |
|---|---|---|---|
| role | No | Case-insensitive regex on the X11 window role. | |
| title | No | Case-insensitive regex on the window title/name. | |
| urgent | No | If set, keep only windows with the urgency hint = value. | |
| floating | No | If set, keep only floating (true) or tiled (false). | |
| instance | No | Case-insensitive regex on the X11 WM_CLASS instance. | |
| workspace | No | Case-insensitive regex on the owning workspace name. | |
| window_class | No | Case-insensitive regex on the window's X11 class. |
Output Schema
| Name | Required | Description |
|---|---|---|
| count | Yes | Number of windows matching the requested filters. |
| windows | Yes | Matching leaf windows, in tree order. |
| truncated | No | True if the result was trimmed to stay under the size limit. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true, destructiveHint=false, and idempotentHint=true. The description adds the cap of 200 windows with a truncated flag and that it returns leaf windows with ids, marks, and location, providing useful behavioral context beyond annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise: five sentences that front-load the main purpose, list filters, provide usage guidance, and mention the cap. No redundant information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the presence of an output schema and rich annotations, the description covers all necessary aspects: return value details (leaf windows with ids, marks, location), usage of id in other tools, and the cap. It is complete for the tool's complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage, with each parameter having a clear description. The tool description does not add additional semantic detail beyond listing the filter options, so baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it lists application windows from the i3/Sway layout tree with optional filters. It distinguishes itself from siblings like get_focused, list_workspaces, and list_outputs by naming them explicitly.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides explicit guidance on when to use this tool (listing windows from the layout tree) and when to use alternatives (get_focused for active window, list_workspaces for workspace summary, list_outputs for monitors). It also explains how to use the returned id with other tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
kill_windowClose i3 WindowADestructive
Close a window — the focused one, or one matched by class/title/instance/mark/con_id. DESTRUCTIVE: the target application is asked to quit and may discard unsaved work; there is no undo, and matching several windows closes all of them. To move a window out of the way instead of closing it, use move_window (e.g. to the scratchpad).
| Name | Required | Description | Default |
|---|---|---|---|
| mark | No | Close the window carrying this mark (criteria). | |
| title | No | Close windows whose title matches (criteria). | |
| con_id | No | Close the container with this exact i3 id (criteria). | |
| instance | No | Close windows whose WM_CLASS instance matches (criteria). | |
| window_class | No | Close windows whose X11 class matches (criteria). |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond annotations (destructiveHint=true), the description details that the target application is asked to quit, unsaved work may be discarded, no undo, and matching several windows closes all. This adds significant context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences: first states purpose, second provides behavioral warning and alternative. Every sentence earns its place, no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with 5 optional criteria parameters, destructive behavior, and an output schema (not shown but indicated), the description covers purpose, criteria, destructive consequences, and alternative usage. No gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so baseline is 3. However, the description adds value by listing the criteria types (class, title, instance, mark, con_id) and implying they are for matching, which reinforces and slightly expands on the schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description explicitly states 'Close a window — the focused one, or one matched by class/title/instance/mark/con_id'. It uses a specific verb ('Close') and resource ('window'), and distinguishes from sibling `move_window` by mentioning the destructive nature and alternative.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides clear guidance: use to close windows, not to move them out of the way (referencing `move_window`). It also warns about destructiveness and multiple windows matching.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_outputsList i3 OutputsARead-onlyIdempotent
List display outputs (monitors): name, active/primary state, current workspace and geometry. Read-only. Use before moving windows or workspaces between monitors with move_window or manage_workspace; for the workspaces themselves use list_workspaces.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| count | Yes | Number of outputs reported. |
| outputs | Yes | Outputs, in i3 order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnly, idempotent, not destructive. Description adds detail on returned fields and confirms read-only nature, providing slight additional value.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, no wasted words, front-loaded with core purpose.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given zero parameters and good annotations, the description fully covers what the tool does and when to use it. Output schema exists, so return values are documented elsewhere.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
No parameters, baseline is 4. Description mentions return fields, no further semantic explanation needed.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states it lists display outputs with specific fields (name, state, workspace, geometry). Distinguishes from sibling tools by mentioning alternatives.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly advises using before moving windows/workspaces between monitors, and directs to list_workspaces for workspace listing.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_workspacesList i3 WorkspacesARead-onlyIdempotent
List all active workspaces with number, name, visibility, focus, urgency and owning output. Read-only. Use this for navigation decisions; for the windows on a workspace use get_tree with a workspace filter, and for monitors use list_outputs.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| count | Yes | Number of active workspaces. |
| workspaces | Yes | Active workspaces, in i3 order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true. Description adds 'Read-only' which is consistent but doesn't disclose additional behavioral traits beyond the annotations. Minimal added value.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences: first covers the action and output, second provides usage context and sibling differentiation. No redundancy or extraneous text.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given zero parameters and the presence of an output schema, the description fully covers the tool's purpose, usage, and relationship to siblings. No gaps remain.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has zero parameters, and schema describes them (vacuously). Baseline 4 per rubric: '0 params = baseline 4'. Description doesn't need to add param details.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'List all active workspaces' and enumerates the specific fields returned. It distinguishes this tool from siblings by contrasting with get_tree and list_outputs.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly says 'Use this for navigation decisions' and provides concrete alternatives: 'for windows on a workspace use get_tree... for monitors use list_outputs'. This is exemplary guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
manage_workspaceManage i3 WorkspaceA
Act on workspaces: switch to one, move_container_to one (optionally following), rename one, or navigate next/prev/back_and_forth. Reversible. action selects the operation and determines which of name/new_name/direction are required. To move a single window rather than switch, use move_window; to list workspaces use list_workspaces.
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Target workspace for switch/move_container_to; old name for rename. | |
| action | Yes | Which workspace operation to perform. | |
| follow | No | For move_container_to, also switch to the target. Default false. | |
| new_name | No | New workspace name (required for `rename`). | |
| direction | No | Navigation direction (required for `navigate`). |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description discloses that the operation is reversible, adding behavioral context beyond the annotations. Annotations indicate a mutation (readOnlyHint=false) but not destructive, and the description aligns with that.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise (two sentences) yet comprehensive. It front-loads the core actions, then adds details about reversibility and parameter dependencies, followed by sibling tool references. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (multiple actions with parameter dependencies) and the presence of an output schema, the description is complete. It covers all necessary behavioral and usage aspects without gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Even with 100% schema description coverage, the description adds significant value by explaining how the action parameter determines which other parameters are required. This is not evident from the schema alone.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: acting on workspaces with specific actions (switch, move_container_to, rename, navigate). It uses specific verbs and resources, and distinguishes from sibling tools like move_window and list_workspaces.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides explicit guidance on when to use each action and which parameters are required. It also suggests alternatives for other tasks (e.g., move_window for moving a single window, list_workspaces for listing).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
move_windowMove i3 WindowA
Move the focused container (or one matched by class/title/instance/mark/con_id) to exactly one destination: a direction (with pixel amount), a workspace, an output, the scratchpad, or a screen position (center). Reversible; returns per-command success. To change focus rather than move, use focus_window; to move whole workspaces between monitors, use manage_workspace.
| Name | Required | Description | Default |
|---|---|---|---|
| mark | No | Select the window to move by mark (criteria). | |
| title | No | Select the window to move by title (criteria). | |
| con_id | No | Select the window to move by exact i3 id (criteria). | |
| instance | No | Select the window to move by WM_CLASS instance (criteria). | |
| amount_px | No | Pixels to move when `direction` is set. Default 10. | |
| direction | No | Move the container this direction. | |
| to_center | No | Center a floating container on its output. Default false. | |
| to_output | No | Move the container to this output, e.g. 'HDMI-1'. | |
| to_workspace | No | Move the container to this workspace (name or number). | |
| window_class | No | Select the window to move by X11 class (criteria). | |
| to_scratchpad | No | Move the container to the scratchpad. Default false. |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond annotations (readOnlyHint=false, destructiveHint=false), the description adds 'Reversible; returns per-command success.' This discloses reversibility and return format, though it doesn't detail side effects or auth requirements.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences with clear front-loading: purpose first, then constraint, then sibling differentiation. No extraneous words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with 11 parameters, 0 required, 100% schema coverage, and output schema, the description covers destination types, selection options, reversibility, and sibling tools. Missing clarification on criteria combination, but adequate.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so baseline is 3. The description adds the constraint 'exactly one destination' but doesn't elaborate on parameter formats or interactions beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool moves a container, specifies selection options (class/title/instance/mark/con_id), and lists possible destinations (direction, workspace, output, scratchpad, screen center). It distinguishes from sibling tools focus_window and manage_workspace.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly tells when to use this tool vs alternatives: 'To change *focus* rather than move, use focus_window; to move whole workspaces between monitors, use manage_workspace.' Also notes 'exactly one destination' to avoid conflicting parameters.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
run_commandRun Raw i3 CommandADestructive
Run a raw i3/Sway command string — the escape hatch for operations without a dedicated tool: marks (mark/unmark), i3-gaps (gaps ...), i3bar (bar ...), scratchpad show/hide, and reload/restart. DESTRUCTIVE / open-world: the payload is unrestricted and CAN include kill, restart, reload, or exit (which logs the user out), so validate before sending. Prefer the typed tools (focus_window, move_window, set_layout, ...) whenever one fits.
| Name | Required | Description | Default |
|---|---|---|---|
| command | Yes | Raw i3/Sway command payload to send. |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate destructiveHint=true and openWorldHint=true. The description adds specific destructive examples (kill, restart, reload, exit) and a validation caveat, providing context beyond the annotations without contradiction.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences with a list of examples, front-loaded with purpose. No unnecessary words; every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given an output schema exists (not detailed but present), the description covers purpose, usage, and warnings adequately. Slight gap: no mention of error handling or return format, but not critical for a raw command tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% for the single parameter 'command'. The description adds value by giving concrete examples of acceptable commands (marks, gaps, etc.), going beyond the schema's generic description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: running raw i3/Sway commands as an escape hatch. It lists specific use cases (marks, gaps, bar, scratchpad, reload/restart) and distinguishes from sibling tools by advising to prefer typed tools when available.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit guidance on when to use (operations without dedicated tool) and when not to (prefer typed tools like focus_window). Also includes explicit warning about destructive nature and advising validation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
set_layoutSet i3 LayoutA
Set how the focused container arranges children: container layout (stacking/tabbed/split*), the split orientation for the next window, and/or the border style. Reversible. Provide at least one of layout/split/border; border_width applies only to the pixel border. For floating/fullscreen/sticky state use toggle_window_state.
| Name | Required | Description | Default |
|---|---|---|---|
| split | No | Split orientation for the next new window. | |
| border | No | Border style for the focused window. | |
| layout | No | Container layout to apply to the focused node. | |
| border_width | No | Border width in px; used only with border='pixel'. |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate readOnlyHint=false and destructiveHint=false, but the description adds 'Reversible', which is important behavioral context. It also clarifies that 'border_width applies only to the pixel border', providing edge-case behavior beyond the schema.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two well-structured sentences with all essential information front-loaded. Every sentence adds value without redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given full schema coverage and presence of an output schema (as per context signals), the description covers all needed context: what the tool does, usage prerequisites, behavioral notes, and cross-reference to a sibling tool for other functionalities.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, but the description adds semantic value by specifying that at least one of layout/split/border is required (schema allows all null) and that border_width is conditional on border='pixel'. This helps the agent form valid invocations.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb ('set') and the resource ('focused container layout, split, border'). It distinguishes from the sibling tool 'toggle_window_state' by directing to it for floating/fullscreen/sticky states, ensuring the agent can differentiate.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly says 'Provide at least one of layout/split/border', giving a clear requirement for parameter selection. Also tells when not to use this tool by referencing 'toggle_window_state' for other window states.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
toggle_window_stateToggle i3 Window StateA
Enable, disable, or toggle one boolean window state — floating, fullscreen, or sticky — on the focused window. Reversible. Omit enable to toggle, or set it true/false to force. fullscreen_scope picks per-output ('normal') vs across-all ('global'). For layout/border changes use set_layout.
| Name | Required | Description | Default |
|---|---|---|---|
| state | Yes | Which boolean window state to change. | |
| enable | No | true=enable, false=disable, omitted=toggle. | |
| fullscreen_scope | No | Fullscreen scope when state='fullscreen'. Default 'normal'. | normal |
Output Schema
| Name | Required | Description |
|---|---|---|
| error | No | First error message across the payload, or null on full success. |
| success | Yes | True only if every command in the payload succeeded. |
| outcomes | No | Per-command outcomes, in payload order. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations are all false and provide minimal information, but the description compensates by stating the operation is reversible and explaining the behavior of enable and fullscreen_scope. It does not mention any side effects, but given the tool's nature, this is sufficient.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is very concise—three sentences with no wasted words. It front-loads the purpose and quickly covers usage details and alternatives.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's moderate complexity (3 params, all documented in schema, and an output schema exists), the description provides complete guidance on how to use each parameter and when to use an alternative tool. No gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% (baseline 3), and the description adds value by clarifying the enable parameter's toggle vs force behavior and the fullscreen_scope meaning (per-output vs across-all). This goes beyond the schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's action: toggle boolean window states (floating, fullscreen, sticky) on the focused window. It distinguishes itself from sibling tool set_layout, which handles layout/border changes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly provides when to use (for boolean window states) and when not to (for layout/border, use set_layout). Also explains the toggle behavior and parameter usage (omit enable to toggle, set true/false to force).
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
12 tool updates
v0.1.0- First observed
exec_application - First observed
focus_window - First observed
get_config - First observed
get_tree - First observed
kill_window - First observed
list_outputs - First observed
list_workspaces - First observed
manage_workspace - First observed
move_window - First observed
run_command - First observed
set_layout - First observed
toggle_window_state
TDQS
Each tool has a distinct purpose: inspecting state (get_tree/list_workspaces/list_outputs/get_config), navigating/focusing (focus_window), moving (move_window/kill_window), workspace management (manage_workspace), layout changes (set_layout/toggle_window_state), and execution (exec_application/run_command). Overlap is minimal and well-documented.
All tool names follow a consistent verb_noun pattern using snake_case, e.g., get_tree, list_workspaces, focus_window, toggle_window_state. No mixing of conventions.
With 12 tools, the scope is well-balanced for an i3/Sway MCP server. It covers essential operations without being bloated or sparse.
The tool set covers most common i3 actions including tree queries, focus, move, workspace management, layout changes, and execution. Minor gaps exist for operations like marks and scratchpad control, but these are accessible via run_command.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Manage Superlist tasks and lists in plain language from any MCP-compatible AI agent.
Operate Linux, macOS and Windows from your LLM. Every action runs through an auditable allowlist.
Provides capabilities that let LLM agents perform a range of infrastructure management tasks.
Deploy, monitor, and manage your OpenClaw AI assistants via natural language.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI assistants to interact with macOS windows through yabai, providing window listing organized by Spaces and screenshot capture capabilities.2MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to manage local tmux sessions, including creating and controlling sessions, windows, and panes, sending commands, and capturing terminal output.1617Do What The F*ck You Want To Public
- FlicenseNot gradedqualityNot gradedmaintenanceEnables interaction with the FVWM3 window manager for configuration generation, window management, and debugging. Provides access to config files, runtime state, and control tools for managing desktops, monitors, and tiling operations.-
- AlicenseAqualityDmaintenanceAllows AI assistants to create, manage, and interact with tmux sessions, windows, and panes programmatically.19MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/kuhyx/i3wm-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server