packages/docs/plugin-registry/computeruse.md
The Computer Use plugin gives Eliza agents the ability to control the desktop — taking screenshots, moving the mouse, clicking, typing, and interacting with any GUI application running on the host machine.
Package: @elizaos/plugin-computeruse
Computer use enables agents to operate the computer as a human would: viewing the screen, making decisions based on what they see, and interacting with the OS and applications through mouse and keyboard. This unlocks automation of any desktop application, not just those with APIs.
eliza plugins install @elizaos/plugin-computeruse
{
"features": {
"computeruse": true
}
}
Or uncomment in OPTIONAL_CORE_PLUGINS in your configuration:
{
"plugins": {
"allow": ["computeruse"]
}
}
| Environment Variable | Required | Description |
|---|---|---|
COMPUTER_USE_ENABLED | No | Enable or disable computer use (default: disabled) |
COMPUTER_USE_SCREENSHOT_AFTER_ACTION | No | Take a screenshot after each action |
COMPUTER_USE_ACTION_TIMEOUT_MS | No | Timeout for individual actions in milliseconds |
COMPUTER_USE_APPROVAL_MODE | No | Require human approval before actions |
COMPUTER_USE_BROWSER_HEADLESS | No | Run the browser in headless mode |
| Platform | Support |
|---|---|
| macOS | Full support |
| Linux (X11) | Full support |
| Linux (Wayland) | Partial support |
| Windows | Full support |
| Action | Description |
|---|---|
TAKE_SCREENSHOT | Capture the current screen state |
MOUSE_MOVE | Move the mouse cursor to coordinates |
MOUSE_CLICK | Click at coordinates or on an element |
MOUSE_DRAG | Click and drag from one point to another |
TYPE_TEXT | Type text using the keyboard |
KEY_PRESS | Press a keyboard shortcut or key combo |
SCROLL | Scroll the mouse wheel |
FIND_ELEMENT | Find a UI element by text or description |
OPEN_APPLICATION | Launch an application by name |
GET_SCREEN_INFO | Get screen resolution and layout |
Computer use works best with a vision-capable model. The workflow:
1. TAKE_SCREENSHOT
↓
2. Send to vision model (e.g., GPT-4o, Claude claude-sonnet-4-6)
↓
3. Model describes what is on screen
↓
4. Agent decides next action
↓
5. Execute action (click, type, etc.)
↓
6. Repeat
Configure a vision-capable model as the primary model:
{
"auth": {
"profiles": {
"default": {
"provider": "anthropic",
"model": "claude-sonnet-4-6"
}
}
},
"features": {
"computeruse": true
}
}
After the plugin is loaded:
"Open Safari and navigate to hacker news"
"Take a screenshot and tell me what application is open"
"Click the Submit button on the form"
"Type 'Hello world' in the terminal"
"Open the System Preferences and take a screenshot of the Privacy settings"
Coordinates are in pixels from the top-left corner of the primary screen:
(0, 0) ──────────────→ x
│
│ screen
│
↓ y
For multi-monitor setups, coordinates extend beyond the primary screen dimensions.
Computer use is a powerful capability. Consider:
Computer use sessions are automatically logged by the trajectories (a core plugin). Logs include screenshots and action sequences for debugging and RL training.
features.computeruse or include computeruse in plugins.allow.CUA_API_KEY for the vision model provider (e.g., Anthropic or OpenAI).CUA_HOST and CUA_SANDBOX_NAME.Screenshot and display:
DISPLAY is set and accessible. In Docker/headless environments, use Xvfb or a virtual framebuffer.Vision model and action loop:
CUA_HOST configuration for remote sandboxes.tool_use_error):
The model may emit malformed tool calls. Check that the CUA plugin's tool schema matches what the model expects. Version mismatches between the plugin and the model API can cause schema drift.Sandbox and isolation:
CUA_HOST is reachable and the sandbox service is running. Check firewall rules and port access. The sandbox name (CUA_SANDBOX_NAME) must match an active session.Cross-platform:
DISPLAY env var) or Wayland equivalent. In containers, use Xvfb. xdotool or equivalent must be available for input simulation.~/.eliza/agents/{agentId}/trajectories/ for the last action sequence.# CUA integration and runtime boundary tests
bunx vitest run src/runtime/computeruse-integration.test.ts
# Runtime plugin loading (includes CUA short-id normalization)
bunx vitest run src/runtime/eliza.test.ts
bun run typecheck