mcpField
M
mcp-pyautogui-server

mcp-pyautogui-server

Local
github.com/hetaoBackendDeveloper Tools46Updated 82w ago

About mcp-pyautogui-server

mcp-pyautogui-server is a PyAutoGUI-based MCP server for users automating GUI control and testing. It exposes mouse, keyboard, and screen operations to clients and supports Windows, macOS, and Linux.

Key features

  1. 01Move, click, and drag the mouse
  2. 02Type text and press key combinations
  3. 03Capture screenshots and get screen size
  4. 04Find screen images and pixel colors

Use cases

  1. 01Automate GUI testing
  2. 02Operate interfaces with mouse and keyboard
  3. 03Inspect screen content and pixel colors

MCP support

The MCP server exposes mouse, keyboard, and screen-operation tools to MCP clients, including screenshots, image location, and screen information.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

No install method listed yet

We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.

Repository

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

mcp-pyautogui-server

smithery badge

A MCP (Model Context Protocol) server that provides automated GUI testing and control capabilities through PyAutoGUI.

Features

  • Control mouse movements and clicks
  • Simulate keyboard input
  • Take screenshots
  • Find images on screen
  • Get screen information
  • Cross-platform support (Windows, macOS, Linux)

Tools

The server implements the following tools:

Mouse Control
  • Move mouse to specific coordinates
  • Click at current or specified position
  • Drag and drop operations
  • Get current mouse position
Keyboard Control
  • Type text
  • Press individual keys
  • Hotkey combinations
Screen Operations
  • Take screenshots
  • Get screen size
  • Find image locations on screen
  • Get pixel colors

Installation

Prerequisites
  • Python 3.12+
  • PyAutoGUI
  • Other dependencies will be installed automatically
Install Steps

Install the package:

pip install mcp-pyautogui-server
Claude Desktop Configuration

On MacOS:

~/Library/Application\ Support/Claude/claude_desktop_config.json

On Windows:

%APPDATA%/Claude/claude_desktop_config.json

Development/Unpublished Servers Configuration:

{
  "mcpServers": {
    "mcp-pyautogui-server": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/mcp-pyautogui-server",
        "run",
        "mcp-pyautogui-server"
      ]
    }
  }
}

Published Servers Configuration:

{
  "mcpServers": {
    "mcp-pyautogui-server": {
      "command": "uvx",
      "args": [
        "mcp-pyautogui-server"
      ]
    }
  }
}

Development

Building and Publishing
  1. Sync dependencies and update lockfile:
uv sync
  1. Build package distributions:
uv build
  1. Publish to PyPI:
uv publish

Note: Set PyPI credentials via environment variables or command flags:

  • Token: --token or UV_PUBLISH_TOKEN
  • Username/password: --username/UV_PUBLISH_USERNAME and --password/UV_PUBLISH_PASSWORD
Debugging

For the best debugging experience, use the MCP Inspector.

Launch the MCP Inspector via npm:

npx @modelcontextprotocol/inspector uv --directory /path/to/mcp-pyautogui-server run mcp-pyautogui-server

The Inspector will display a URL that you can access in your browser to begin debugging.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.