computer-use-mcp

computer-use-mcp

3.3

If you are the rightful owner of computer-use-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

Control virtual computers through the Model Context Protocol (MCP). Built with FastMCP and Orgo.

Computer Use MCP Server 🖥️

Control virtual computers through the Model Context Protocol (MCP). Built with FastMCP and Orgo.

Spin up cloud desktop environments for Computer Use Agents (CUA).

Quick Start

1. Install Dependencies

# Create virtual environment
python3 -m venv mcp-env
source mcp-env/bin/activate

# Install packages
pip install fastmcp pydantic orgo

2. Get API Keys

3. Run Server

# Set environment variables
export ORGO_API_KEY="your_orgo_key"
export ANTHROPIC_API_KEY="your_anthropic_key"

# Start server
python computer_mcp_server.py

Server runs on http://127.0.0.1:9000

Test Client

import asyncio
from fastmcp import Client

async def demo():
    async with Client("http://127.0.0.1:9000/mcp") as client:
        # Initialize computer
        result = await client.call_tool("initialize_computer", {
            "api_key": "your_orgo_key"
        })
        print(f"Computer ready: {result[0].text}")
        
        # Take screenshot
        screenshot = await client.call_tool("get_screenshot")
        print("Screenshot taken!")
        
        # Click and type
        await client.call_tool("left_click", {"x": 100, "y": 200})
        await client.call_tool("type_text", {"text": "Hello World"})
        await client.call_tool("press_key", {"key": "Enter"})

if __name__ == "__main__":
    asyncio.run(demo())

Available Tools

ToolDescription
initialize_computerStart virtual computer
get_screenshotTake screen capture
left_click, right_click, double_clickMouse actions
scrollScroll up/down
type_text, press_keyKeyboard input
waitWait for specified seconds
execute_bashRun terminal commands
restart_computer, shutdown_computerComputer lifecycle
get_status, list_sessionsStatus and session management
promptClaude AI Computer Use

Claude AI Computer Use Example

# Let Claude control the computer
await client.call_tool("prompt", {
    "instruction": "Open Firefox and go to google.com"
})

Requirements

  • Python 3.8+
  • Orgo API key
  • Anthropic API key (for Claude CUA)