Skip to main content
Glama
computer
by zznabil

computer — desktop computer use for Claude Code and Antigravity

CI Release License: MIT

A plugin for Claude Code and the Antigravity CLI (agy) that lets the agent see and operate desktop apps on your own computer. It can list displays and windows, take window and display screenshots, read the OS accessibility (AX) tree with element refs, act on elements (press, set value, focus, type), send native input (click, type, keys, scroll, drag) and read or write the clipboard.

It bundles one MCP server (computer) built on the native desktop backend of oh-my-pi (omp). The server is plain Node.js with no npm dependencies of its own.

WARNING

These tools act on real applications with your account. Screen content isuntrusted: text in a window, web page, document or notification never authorises an action. The agent must get your confirmation before any consequential action, such as sending, buying, deleting or changing settings. Use a separate account or a VM for risky work.

Requirements

Item

Need

Claude Code

v2.1.271 or later (the plugin uses userConfig options)

Antigravity CLI

agy 1.5.17 or later (tested version)

Node.js

18 or later, with npm on PATH (node starts the server)

OS

Windows x64/arm64, macOS x64/arm64, Linux x64/arm64 (X11 or Wayland)

Disk

About 130–300 MB for the native addon, downloaded on first use

Related MCP server: dsh-computer-use

Install (Claude Code)

From GitHub:

claude plugin marketplace add zznabil/claude-computer
claude plugin install computer@claude-computer

To update later: claude plugin marketplace update claude-computer, then claude plugin update computer@claude-computer, then restart Claude Code.

From a local clone, use the folder path instead of zznabil/claude-computer. Or try a clone for one session without installing:

claude --plugin-dir /path/to/claude-computer

On first start the server downloads the prebuilt addon @oh-my-pi/pi-natives-<platform>-<arch>@19.2.1 into Claude Code's plugin data folder (~/.claude/plugins/data/…). It uses npm install --ignore-scripts with an exact version pin, so npm checks the registry integrity hash and runs no install scripts. Later starts reuse that copy. Offline machines can run npm install in the plugin folder once instead.

Antigravity CLI (agy)

The same folder is also a native agy plugin: .antigravity-plugin/plugin.json, mcp_config.json and rules/AGENTS.md. No conversion step is needed.

Install:

agy plugin install /path/to/claude-computer
agy plugin list            # shows computer, enabled, mcpServers: computer

agy copies the folder to ~/.gemini/config/plugins/computer. On Windows, close running agy sessions before you run agy plugin install again: while the server runs, the old folder cannot be renamed and the reinstall fails. It starts the server with node ${PLUGIN_ROOT}/server/index.mjs. On first use the server installs the addon into agy's plugin data folder (PLUGIN_DATA, for example ~/.gemini/antigravity-cli/plugin_data/computer). To update, run agy plugin install again. To remove, run agy plugin uninstall computer.

agy names the server computer_computer (plugin computer, server computer). The agent calls tools through agy's call_mcp_tool. rules/AGENTS.md gives the agent the same workflow and safety rules as the MCP server instructions.

Approvals. agy ignores readOnlyHint. Each MCP tool without a rule is Ask, and headless agy -p auto-denies it. To allow the 12 inspection tools and keep every input tool on Ask, add this to ~/.gemini/antigravity-cli/settings.json:

{
  "permissions": {
    "allow": [
      "mcp(computer_computer/capabilities)",
      "mcp(computer_computer/list_displays)",
      "mcp(computer_computer/list_windows)",
      "mcp(computer_computer/list_applications)",
      "mcp(computer_computer/screenshot)",
      "mcp(computer_computer/observe)",
      "mcp(computer_computer/ax_tree)",
      "mcp(computer_computer/ax_find)",
      "mcp(computer_computer/ax_element)",
      "mcp(computer_computer/ax_element_at)",
      "mcp(computer_computer/ax_focused)",
      "mcp(computer_computer/clipboard_read)"
    ]
  }
}

For one session only, pass the same JSON with agy --settings '<json>'. The rule must name computer_computer: mcp(computer/...) does not match. Do not use --dangerously-skip-permissions for real work: it approves every input tool too.

Settings. agy has no plugin options dialog. Put a settings.json in the plugin data folder:

{ "takeover": "refuse", "max_width": 1366, "max_height": 768 }

It survives plugin updates. Environment variables override it (COMPUTER_TAKEOVER, COMPUTER_MAX_WIDTH, COMPUTER_MAX_HEIGHT), for example in the installed mcp_config.json env, but reinstalling replaces that file. The capabilities tool shows the active host, data folder, settings and where each setting came from.

Limits in agy. Screenshots return as MCP image content; what the model sees depends on agy's image support. The instructions from the MCP server are stored by agy, and rules/AGENTS.md repeats them, so the agent gets the guidance either way. agy has no /config for plugin options; use settings.json.

Enable and configure (Claude Code)

The plugin is enabled after you install it. To check, run /plugin in Claude Code, or claude plugin list. /mcp must show plugin:computer:computer as connected.

Optional settings: run /plugin configure computer@claude-computer, or use /config.

Setting

Default

Effect

takeover

fallback

Window input always tries the background first. fallback: when an app rejects background input (for example XAML/WinUI apps on Windows), the server reruns that one call in takeover. Takeover briefly brings the window forward, sends real input, then hands focus back. refuse: never takes over your pointer or keyboard. Such calls fail before anything is sent. It also refuses, as omp does: takeover: true, desktop/display input, raise_window, element_press with a raise action, open_application with activate or reveal, and (off macOS) element_focus. On macOS it also refuses calls that open a menu (right-click, Control-click, any menu path, open/showMenu actions, pressing or setting a popup or menu button), and asks the addon to refuse a click or drag that lands on one.

max_width / max_height

1366 / 768

Largest screenshot size sent to the agent. Larger captures are scaled down, and input coordinates follow the delivered image.

The same settings.json in the plugin data folder (~/.claude/plugins/data/computer-…/settings.json) also works in Claude Code, but the /config options above pass as environment variables, and those win. Precedence per setting: environment variable, then settings.json (keys takeover, max_width, max_height, call_timeout_ms, install_timeout_ms), then the default. Data folder: CLAUDE_PLUGIN_DATA (Claude Code), PLUGIN_DATA (agy), else ~/.cache/claude-computer.

Environment overrides for advanced use: COMPUTER_CALL_TIMEOUT_MS (default 120000; a call past it is cancelled and fails with Timeout) and COMPUTER_INSTALL_TIMEOUT_MS (default 600000; the first-run npm install is killed past it).

Approvals: inspection vs input

Every tool has MCP annotations. The 12 inspection tools carry readOnlyHint: true. The 19 other tools carry readOnlyHint: false. Input and mutation tools also carry destructiveHint: true. menu_items is not read-only: on macOS reading a menu first makes its window key, so omp treats it as an action too.

  • In plan mode, Claude Code runs the read-only tools without asking (tested with Claude Code 2.1.332: the read-only capabilities tool ran with no prompt).

  • In default mode, Claude Code asks for every MCP tool the first time. To approve all inspection tools at once and keep a prompt for input, add this to ~/.claude/settings.json or .claude/settings.json:

{
  "permissions": {
    "allow": [
      "mcp__plugin_computer_computer__capabilities",
      "mcp__plugin_computer_computer__list_displays",
      "mcp__plugin_computer_computer__list_windows",
      "mcp__plugin_computer_computer__list_applications",
      "mcp__plugin_computer_computer__screenshot",
      "mcp__plugin_computer_computer__observe",
      "mcp__plugin_computer_computer__ax_tree",
      "mcp__plugin_computer_computer__ax_find",
      "mcp__plugin_computer_computer__ax_element",
      "mcp__plugin_computer_computer__ax_element_at",
      "mcp__plugin_computer_computer__ax_focused",
      "mcp__plugin_computer_computer__clipboard_read"
    ]
  }
}

clipboard_read and screenshots can expose private data. Leave them out of the list if you want a prompt for those too.

Use

Ask in plain words, for example:

  • "List my open windows."

  • "Take a screenshot of the Notepad window and tell me what it says."

  • "In the Settings window, turn on Dark mode." The agent reads the AX tree, then presses the switch by ref.

Typical flow the agent follows:

  1. list_windows → pick a window id.

  2. ax_tree (refs like e12) and/or screenshot.

  3. Act by ref (element_press, element_set_value, element_type) for exposed controls. Use pixels (click, drag, scroll) for canvases and custom-drawn UI.

  4. Check the result with a fresh ax_tree or screenshot.

Tools

Kind

Tools

Inspect (read-only)

capabilities, list_displays, list_windows, list_applications, screenshot (with region = zoom), observe (screenshot + tree), ax_tree, ax_find, ax_element, ax_element_at, ax_focused, clipboard_read

Act on elements

element_press (default press, or any named AX action, optional menu path), element_set_value, element_focus, element_click, element_type, element_press_keys, element_select_text

Native input

click, move_mouse, drag, scroll, type_text, press_keys

Other

menu_items (not read-only, see above), menu_select, raise_window, open_application, clipboard_write, reset_session

Targets: a window id from list_windows, "desktop", or "display:<id>", "display:active" or "display:all".

Coordinates: pointer x,y are pixels in the latest full screenshot of the same target. AX bounds and ax_element_at use global desktop coordinates. Do not mix the two.

Background input

Window input goes to the target window without moving your pointer or bringing the window forward, as in omp. You can keep working in another app. Desktop and display targets drive your real pointer and keyboard, so the agent is told to act through window ids. If you press Esc during takeover input, the input stops. The next computer call then fails with UserStopped, and the agent must stop and report.

Limits

  • Background input depends on the app. On Windows, XAML/WinUI hosts (for example the current Notepad) ignore background keystrokes. With takeover: fallback those calls briefly take over; with refuse they fail. AX actions (element_set_value, element_press) still work in the background.

  • Takeover on Windows is subject to the OS foreground lock (ForegroundLockTimeout, 200 s by default). Windows sometimes refuses to activate the target (InputFailed: Windows refused to activate the exact target window …; no input was sent). This is intermittent and depends on which app is in front and on recent user input. It also fails when no window is in the foreground (cannot save the current foreground window). Nothing is sent in either case. Use an AX route (element_set_value), or element_focus on a control of the window and retry once.

  • Some apps refuse background UI Automation actions (element_press returns BackgroundUnavailable … use coordinate input instead), as in omp. Use element_click, or menu_select for menu commands; menu_select works in the background on Win32 menus.

  • Elevated (admin) windows, UAC and secure desktops, and a locked screen block input. capabilities and screenshot notes report a lock.

  • macOS: grant Screen Recording and Accessibility to the app that runs Claude Code or agy (your terminal or IDE), then restart it. Without Screen Recording, other apps' window titles are empty.

  • Linux X11 needs RandR/XTEST and AT-SPI. On Wayland, per-window background input and raise_window are unavailable, capture needs the ScreenCast portal and libpipewire-0.3, and input asks for RemoteDesktop permission. Only Windows was tested live for this release; macOS and Linux use the same addon but are untested here.

  • Some calls are macOS-only in the backend (element_select_text, Spaces). open_application returns a window only on macOS. Unsupported calls fail with an explicit error.

  • Not exposed from omp: held keys/mouse (holdKeys/holdMouse), task-scoped control.acquire (it needs omp's live confirmation UI), and the scriptable computer.run JavaScript runner. The agent chains the single tools instead.

  • Element refs and screenshot frames live in one native session per server process. reset_session, or a server restart, drops them. Re-read after that.

  • One tool call runs at a time. A call that hits its deadline is cancelled and the queue moves on. Native work that cannot be interrupted (for example an application scan) may finish first, so the next call can wait briefly.

  • list_windows returns [] when Windows finds no top-level window (the addon reports that case as error 0). Its app filter prefers exact app names, then substrings, as in omp.

  • open_application takes app and reveal only on macOS; other platforms throw Unsupported for them.

  • The server closes its native session when the host (Claude Code or agy) closes the connection or on SIGINT/SIGTERM. On Windows a forced kill skips that step; the OS then releases the session.

Why reuse the omp addon

omp's desktop backend is a large Rust codebase: capture, Win32/macOS/X11/Wayland input, UI Automation, AX and AT-SPI. Its @oh-my-pi/pi-natives 19.2.1 release ships it prebuilt for six platforms under MIT. Reimplementing it would cost far more and lose its background-input and safety work. This plugin loads that addon unchanged. omp's own JS loader needs Bun (import.meta.dir), so server/native.mjs loads the .node file directly from Node and checks that it has the required desktop methods. The MCP layer is a small dependency-free stdio server. It answers initialize at once, even while the addon downloads.

Credits and history

  • Native backend and the design of the tools, input policy and safety guidance: oh-my-pi by Can Bölük, Mario Zechner and Stencil Labs, Inc. (MIT). See NOTICE.

  • omp's computer use started as native support for OpenAI Codex's computer-use tool, in commit b9504f65e7 "feat: add native Codex computer use" (2026-07-23). That commit first added crates/pi-natives/src/desktop.rs, docs/computer-use.md and docs/tools/computer.md. A day later, 681d7daf65 "feat(computer): unified native addon, /computer toggle, function tool" (2026-07-24) made it a general tool.

  • This plugin: MIT, see LICENSE.

Development

npm install          # optional: puts the addon for this platform in ./node_modules
npm test             # protocol, annotation and refuse-policy tests (no input sent)
claude plugin validate .
agy plugin validate . --strict
node test/client.mjs '[["list_windows",{}]]'   # call tools from a shell
node test/live-notepad.mjs   # Windows: opens its own scratch Notepad, types, reads back, closes without saving
node test/live-agy.mjs       # Windows + installed agy plugin: agy itself drives a scratch Notepad round-trip
node scripts/make-icon.mjs   # regenerate assets/icon.png (Node zlib only, no external assets)

Available Tools

31 tools
ax_elementInspect elementA
Read-onlyIdempotent

Read one element by ref: role, title, value (full), bounds, actions; optionally its attributes, children and parent.

Inputs: ref (required), parent, children, attributes.

ax_element_atElement at pointA
Read-onlyIdempotent

Accessibility hit-test at GLOBAL logical desktop coordinates (as in ax_find bounds / list_windows, not screenshot pixels).

Inputs: x (required), y (required), target.

ax_findFind elementsA
Read-onlyIdempotent

Query a window's AX tree by role/title/value; returns element records with refs and global desktop bounds.

Inputs: target (required), role, limit, title, +1 more.

ax_focusedFocused elementB
Read-onlyIdempotent

The element holding keyboard focus, or null.

Inputs: no named parameters.

ax_treeAccessibility treeA
Read-onlyIdempotent

OS accessibility tree of a window as text, one node per line: - role "label" [ref=eN]: "value" plus states. Refs stay valid across reads until the element's role/label changes; a ref missing from the last two reads throws StaleRef (re-read, never guess).

Inputs: target (required), all, maxDepth, maxNodes.

capabilitiesComputer capabilitiesB
Read-onlyIdempotent

Backend, permissions, display count, lock state, takeover setting and loaded addon.

Inputs: no named parameters.

clickClickA
Destructive

Click at screenshot pixels in a target window (background by default, without moving the user's pointer).

Inputs: x (required), y (required), target (required), menu, +4 more.

clipboard_readRead clipboardA
Read-onlyIdempotent

Read clipboard text; with image: true, the clipboard image as PNG instead.

Inputs: image.

clipboard_writeWrite clipboardB
Destructive

Replace the clipboard with text.

Inputs: text (required).

dragDragB
Destructive

Drag along a path of screenshot pixels, optionally holding keys/modifiers.

Inputs: path (required), target (required), keys, button, +2 more.

element_clickClick elementB
Destructive

Click the centre of an element by ref (no screenshot needed).

Inputs: ref (required), menu, count, button, +2 more.

element_focusFocus elementB
Destructive

Give an element keyboard focus. Off macOS this can bring its window forward.

Inputs: ref (required).

element_pressPress elementA
Destructive

Perform an accessibility action on an element: default "press"; others from ax_element actions (e.g. "showMenu", "increment"). With menu, choose that item path in the menu the action opens. If it returns BackgroundUnavailable, use element_click (coordinate input) instead.

Inputs: ref (required), menu, action.

element_press_keysPress keys in elementA
Destructive

Press a key chord in an element once it holds keyboard focus.

Inputs: ref (required), keys (required), takeover.

element_select_textSelect text in elementB
Destructive

Select text inside an element's value (or place a caret) without focus change or keystrokes; returns the selection read back. macOS backend.

Inputs: ref (required), text (required), prefix, select, +1 more.

element_set_valueSet element valueA
Destructive

Set an element's value through accessibility (text fields, sliders, pickers) without keystrokes.

Inputs: ref (required), value (required).

element_typeType into elementA
Destructive

Type text into an element: native text fields take it by AX insertion, others as keystrokes once focused.

Inputs: ref (required), text (required), takeover.

list_applicationsList applicationsA
Read-onlyIdempotent

Installed/running applications with ids usable by open_application.

Inputs: query, runningOnly.

list_displaysList displaysB
Read-onlyIdempotent

Monitors with global logical geometry and pixel size.

Inputs: no named parameters.

list_windowsList windowsA
Read-onlyIdempotent

Capturable top-level windows: {id, app, title, pid, x, y, width, height, focused}. app prefers exact app names (case-insensitive) and falls back to substrings, as in omp; title is a case-insensitive substring. A failed title filter does not prove a window is absent.

Inputs: app, limit, title.

move_mouseMove pointerB
Destructive

Move the pointer to screenshot pixels in a target (background moves give no hover).

Inputs: x (required), y (required), target (required), takeover.

observeScreenshot + accessibility treeB
Read-onlyIdempotent

Screenshot and AX tree of one target in one call.

Inputs: target (required), all, maxDepth, maxNodes, +2 more.

open_applicationOpen applicationA
Destructive

Launch an application by id/path/unique name from list_applications (behind the user's app unless activate). On macOS it also opens a file, folder or URL (in its default app, or app), or with reveal shows it selected in Finder, and returns the window; other platforms throw Unsupported for URLs, app and reveal.

Inputs: id (required), app, reveal, activate.

press_keysPress keysB
Destructive

Press a key chord in the target window.

Inputs: keys (required), target (required), takeover.

raise_windowRaise windowA
Destructive

Bring a window to the front. It takes the user's keyboard; never use it just to make input work (background input reaches covered windows).

Inputs: id (required).

reset_sessionReset sessionA
Idempotent

Close the native desktop session: drops screenshot frames and element refs. The next call opens a new one.

Inputs: no named parameters.

screenshotScreenshotA
Read-onlyIdempotent

Capture a window or display as PNG. Pointer x,y for input tools are pixels of the latest FULL screenshot of the same target. With region, returns a zoomed detail view that does not change that input frame.

Inputs: target (required), region, maxWidth, maxHeight.

scrollScrollB
Destructive

Scroll at screenshot pixels. Positive dy scrolls down, positive dx right (wheel detents).

Inputs: x (required), y (required), target (required), dx, +2 more.

type_textType textA
Destructive

Type text into the target window's focused control. To type into a known field prefer element_type or element_set_value.

Inputs: text (required), target (required), takeover.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 31 tools

    Disambiguation4/5

    Most tools have clearly distinct roles, and descriptions explicitly differentiate coordinate-based input from accessibility-based operations (click vs element_click, type_text vs element_type, press_keys vs element_press_keys). Some overlap remains between observe/screenshot/ax_tree and within the element_* family, but the guidance reduces misselection.

    Naming Consistency4/5

    Predominantly snake_case with clear ax_, element_, and clipboard_ prefixes. Minor deviations include bare verbs/nouns (click, drag, scroll, observe, screenshot, capabilities) and noun-first forms like clipboard_read and clipboard_write.

    Tool Count3/5

    31 tools is heavy for a single server, though desktop automation is a broad domain. observe duplicates screenshot plus ax_tree, and several element_* wrappers overlap with generic input tools, so consolidation could bring the surface closer to 20.

    Completeness4/5

    Covers discovery, observation, accessibility inspection, input, menus, clipboard, and session lifecycle thoroughly. Minor gaps include window manipulation (resize/close/minimize), clipboard image write, and element-level drag operations.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables AI agents to observe and control the user's live desktop by listing apps, reading accessibility trees, and performing clicks, typing, scrolling, dragging, and other input actions with per-action approvals and local audit archives.
      1
      MIT
    • A
      license
      C
      quality
      C
      maintenance
      Enables agent-native desktop control by driving mouse, keyboard, and interface elements through accessibility-first semantic operations, with fallback to screen coordinates when accessibility cannot reach a target.
      30
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables an agent to observe and operate desktop apps and browsers through an accessibility-tree-first view, with clicking, typing, scrolling, dragging and waiting tools. Screenshot handling, coordinate mapping and fail-closed safety rules (risk confirmation, deny-listed apps, stale-observation refusal) are enforced inside the server.
      9
      Apache 2.0