agentsys
AI writes code. This automates everything else · 24 plugins · 49 agents · 44 skills · for Claude Code, OpenCode, Codex, Cursor, Kiro.
Linux desktop control over MCP — AT-SPI, GNOME Shell, Wayland portals, ydotool
$ npx -y skills add agent-sh/computer-use-linux --agent claude-code
Repo: agent-sh/computer-use-linux
What's inside
⚡ Running this agent 24/7? tiyuvta inference — hosted LLM inference built for always-on agents, OpenAI/Anthropic-compatible APIs.
computer-use-linux reads accessibility trees, takes screenshots, and drives clicks, scrolls, and keystrokes across GNOME, KDE/KWin, Hyprland, i3, and COSMIC — Wayland-first, X11 best-effort.
npm install -g @agent-sh/computer-use-linux
computer-use-linux doctor | jq .readiness
The Rust crate is published as computer-use-linux and the npm wrapper as @agent-sh/computer-use-linux. Prebuilt binaries ship with the latest release.
computer-use-linux is a Rust MCP server and CLI for Linux desktop control. The crate ships the main computer-use-linux binary plus a small computer-use-linux-cosmic helper used only for COSMIC Wayland window management. Any MCP host — Codex Desktop's Linux build, Claude Desktop, Hermes Agent, or your own client — can spawn it and gain full control of the local Linux desktop: read accessibility trees, list and focus windows, take screenshots, click, drag, scroll, type, and invoke semantic accessibility actions.
Most computer-use MCP servers are macOS-only (they lean on AppKit, AXUIElement, CGEvent). The few that target Linux either drive xdotool against an X11 root window or shell out to OCR over screenshots. Four things set this one apart:
org.freedesktop.portal.RemoteDesktop interface on Wayland, with ydotool / ydotoold (uinput) as the deterministic fallback. Literal text prefers wtype on compatible Wayland compositors when portal keyboard input is unavailable, preserving Unicode and the active layout before falling back to ydotool. Screenshots use the GNOME Shell DBus screenshot method when present, org.freedesktop.portal.Screenshot otherwise, and fall back to spawning gnome-screenshot for background/systemd contexts where both DBus paths are denied.hyprctl, i3 IPC, and generic X11/EWMH in order, then reports exactly which backend won or why each backend failed.click, perform_action, and set_value accept role / name / text / states selectors backed by AT-SPI. Pixel coordinates remain available as a fallback for rendering-only surfaces (canvas, games, X clients without ATK).computer-use-linux doctor returns a structured document covering platform, portals, AT-SPI, windowing, input, and a readiness summary with explicit blockers and a recommended next step. MCP hosts can render or surface that to the user without parsing prose.The crate was extracted from codex-desktop-linux (the Linux distribution of Codex Desktop), which still bundles this binary as a built-in plugin. This standalone repo is the upstream.
MCP tools exposed by the server:
Diagnostics
doctor — single-shot JSON readiness report (platform, portals, accessibility, windowing, input, readiness summary, and a capability map of available backends)setup_accessibility — enables GNOME's org.gnome.desktop.interface toolkit-accessibility setting so toolkit apps expose AT-SPI treessetup_window_targeting — installs and enables the bundled GNOME Shell extension when org.gnome.Shell.Introspect is locked downDiscovery
list_apps — running desktop apps visible to the AT-SPI registrylist_windows — compositor windows with title, app id, wm_class, focus state, client type (Wayland/X11), and boundsfocused_window — the window currently holding keyboard focusget_app_state — combined screenshot + accessibility tree for a chosen app, with element indices that the input tools accept. Scope it with app_name_or_bundle_identifier or a window target; an unscoped call returns the whole desktop tree, reports tree_scoped: false, and warnsscreenshot — capture the screen as a bounded PNG or JPEG image; can target a window, which is raised to the front and cropped to just that windowScreenshot payloads are size-bounded by default before they are returned to the MCP host: max 1920 px width/height and 2 MiB image bytes, with hard caps even when callers request more. Agents that need more detail can pass max_width, max_height, max_bytes, scale, format: "jpeg", or quality, preferably with a window target or crop. PNG remains the default; JPEG lets callers trade lossless pixels for a smaller payload before the byte cap forces further resizing. Returned screenshot metadata includes coordinate_width, coordinate_height, scale, format, and quality so callers can convert from a downscaled preview to desktop coordinate pixels.
Input
click — by element index, semantic selector, or desktop coordinate pixelsdrag — desktop coordinate drag (start / end)scroll — page-based scroll on an element or at a pixel locationpress_key — keys / chords; can focus a window or terminal firsttype_text — literal text input, optionally targeted at a window or terminalFor a plain left click by element index or selector, a recognized native
AT-SPI click, press, or toggle action takes precedence
over bounds. Entry activate and slider jump must be requested explicitly
with perform_action; they are never a substitute for a pointer click, even
when bounds are missing.
This avoids pointer conversion for GTK3 HiDPI
extents and GTK4 zero-origin bounds when the element exposes such an action.
The preference does not substitute an arbitrary action name for a coordinate
click. Explicit x/y, right clicks, and double/multiple clicks retain pointer
semantics. Re-check application state after either kind of activation.
For coordinate click or scroll with relative: true, select a target window
and measure from its clipped screenshot crop origin. Divide preview x and
y by the returned screenshot scale before passing them. These are not raw
GDK surface or widget-local coordinates; decorations and clipping can change
the origin. A missing window target is rejected.
Targeted press_key/type_text results append focused-element feedback from AT-SPI (role, name, editable) and warn when no editable element holds focus. Click/screenshot/input results warn when the target window or coordinate is partially or fully off-screen. get_app_state returns a compact readiness block by default; pass verbose: true for the full diagnostics report. It also reports tree_scoped (false when no app target narrowed the AT-SPI tree, with a warning in message) and accessibility_tree_truncated (true when the node, depth, or read budget stopped traversal with unread elements left).
Semantic actions
perform_action — invoke any AT-SPI action exposed by an element (Press, Activate, Toggle, …); defaults to the primary actionset_value — write to a settable accessibility element (text fields, sliders, spinners)Navigation
activate_window — focus a window by window_id, pid, app_id, wm_class, title, or terminal selectorsmove_window / resize_window — reposition or resize a window in desktop coordinates (GNOME Shell extension backend); useful to recover windows that are partially off-screenConditional host execution
complete_interaction - optional desktop completion notification, registered only with COMPUTER_USE_LINUX_NOTIFY_ON_COMPLETE=1. Repeated calls can create repeated notifications; it does not provide desktop exclusivity.
run_shell — same-user /bin/sh -c execution without login-profile loading, registered only when the server operator starts the MCP process with COMPUTER_USE_LINUX_ENABLE_SHELL=1. It is deliberately absent by default and is not a sandbox.
computer-use-linux is not a read-only data source. It can observe the local desktop and, when a mutating tool is called, can change real application state. The tools/list response includes MCP ToolAnnotations so hosts can surface this distinction before invocation:
| Class | Tools | Contract |
|---|---|---|
| Read-only observation | doctor, list_apps, list_windows, focused_window, get_app_state | readOnlyHint=true; may reveal app, window, accessibility, and screenshot contents. get_app_state may trigger the desktop screenshot portal prompt. |
| Local setup mutators | setup_accessibility, setup_window_targeting | readOnlyHint=false, destructiveHint=false, idempotentHint=true; modifies user desktop configuration by enabling accessibility or installing/enabling the GNOME window-targeting extension. |
| UI state mutators | activate_window, move_window, resize_window, scroll, screenshot | readOnlyHint=false, destructiveHint=false; changes focus, geometry, or scroll position in the live desktop, or raises a window to capture it. |
| Desktop action mutators | click, drag, press_key, type_text, perform_action, set_value | readOnlyHint=false, destructiveHint=true, openWorldHint=true; can trigger arbitrary actions in whatever local application is targeted. |
| Conditional host-code execution | run_shell | Absent unless COMPUTER_USE_LINUX_ENABLE_SHELL=1; when enabled, readOnlyHint=false, destructiveHint=true, idempotentHint=false, openWorldHint=true. Runs with the MCP server user's host permissions. |
Annotations are safety hints, not an authorization system. MCP hosts should still ask the user before calls that could submit, delete, send, purchase, overwrite, or otherwise commit state.
run_shell is an explicit trust-boundary opt-in, not a restricted command runner. Enabling it grants an approved MCP call the same file and network authority as the user running the server. The tool clears the ambient environment and inherits only a small desktop/runtime allowlist (PATH, home/user/locale fields, display/session-bus fields); additional variables must be supplied in the visible call payload. Commands use a fixed non-login /bin/sh, an existing canonical working directory, a 30-second default / 120-second hard timeout, process-group cleanup, and stderr audit records keyed by the command SHA-256 rather than command text. Collected streams up to 8 MiB are returned with a 512 KiB per-stream response cap and truncation flag; exceeding 8 MiB on either stream fails the call without partial output. These controls bound accidental leakage and runaway work; they do not make arbitrary shell code safe.
The binary also exposes the same capabilities from the CLI for scripting and debugging:
AI writes code. This automates everything else · 24 plugins · 49 agents · 44 skills · for Claude Code, OpenCode, Codex, Cursor, Kiro.
The missing linter and lsp for AI coding assistants. Validate CLAUDE.md, AGENTS.md, SKILL.md, hooks, MCP. Plugin for all major IDEs included, with autofixes.
FAQ
computer-use-linux is a Claude Code plugin with 1 hand-picked skill for automation work, indexed on Flowy. Install it with the command on its page. It includes computer-use-linux. Its skills do not fire on their own yet. Request auto-invocation to have Flowy route them as you prompt. Free and open source.
Is this plugin yours?
Claim it with GitHubSubmit a pluginPromote it