MCP cover image
See in Github
2025-03-30

1

Github Watches

0

Github Forks

1

Github Stars

TRAA MCP Server

TRAA MCP Server is a screen capture server based on the Model Context Protocol (MCP). It provides functionality for enumerating system screens and windows, as well as capturing screenshots. The server communicates with clients through the MCP protocol, supporting both standard input/output (stdio) and Server-Sent Events (SSE) transport methods.

Features

  • Screen and Window Source Enumeration

    • List all available displays in the system
    • List all available windows in the system
    • Each source includes ID, title, type (display/window), and position information
  • Screen Capture

    • Capture screenshots of any display or window
    • Customizable screenshot dimensions
    • Support for both JPEG and PNG formats
    • Configurable image quality settings
    • Automatic directory creation for saving files

Tools

  1. enum_screen_sources

    • Enumerate all screen and window sources available on the system and return a list of SimpleScreenSourceInfo
    • Returns: list[SimpleScreenSourceInfo]
  2. create_snapshot

    • Create a snapshot of the screen source with the given ID and return it as an image
    • Inputs:
      • source_id: int
      • snapshot_size: tuple[int, int]
    • Returns: Image
  3. save_snapshot

    • Save a snapshot of the screen source with the given ID to a file
    • Inputs:
      • source_id: int
      • snapshot_size: tuple[int, int]
      • file_path: str
    • Returns: None

Example

Example Example Example

Usage

Configure MCP Servers

Claude Desktop or other AI agents

{
    "mcpServers": {
        "traa_mcp": {
            "command": "absolute/path/to/uv",
            "args": [
                "--directory",
                "absolute/path/to/traa-mcp",
                "run",
                "traa_mcp_server"
            ]
        }
    }
}

Server Side

The server supports two running modes:

  1. stdio mode (default):
uv run traa_mcp_server
  1. SSE mode (with port specification):
uv run traa_mcp_server-sse --port 3001(default)

Client Side

The client provides an interactive command-line interface for easy access to server functionality:

uv run traa_mcp_client

After starting, the client displays a list of all available tools. You can:

  1. Use enum_screen_sources to view all available screen and window sources
  2. Use create_snapshot to capture screenshots and get image data
  3. Use save_snapshot to save screenshots directly to files

Image Format Support

  • JPEG Format

    • Best for screenshots with many colors
    • Smaller file size
    • Quality setting available (1-100)
    • Automatically converts to RGB color space
  • PNG Format

    • Best for screenshots with text or sharp edges
    • Lossless compression
    • Supports transparency (RGBA)
    • Larger file size but better quality

Dependencies

  • Python >= 3.10
  • mcp >= 1.0.0
  • anyio >= 4.5
  • traa >= 0.1.5
  • pillow >= 11.1.0 (for image processing)

Notes

  • For MCP model compatibility, JPEG format with quality=60 is used by default to keep file sizes under 1MB
  • When saving files, parent directories are automatically created if they don't exist
  • Error handling includes detailed messages for easier troubleshooting

License

See the LICENSE file for details.

相关推荐

  • NiKole Maxwell
  • I craft unique cereal names, stories, and ridiculously cute Cereal Baby images.

  • https://suefel.com
  • Latest advice and best practices for custom GPT development.

  • Yusuf Emre Yeşilyurt
  • I find academic articles and books for research and literature reviews.

  • https://maiplestudio.com
  • Find Exhibitors, Speakers and more

  • Carlos Ferrin
  • Encuentra películas y series en plataformas de streaming.

  • Bora Yalcin
  • Evaluator for marketplace product descriptions, checks for relevancy and keyword stuffing.

  • Joshua Armstrong
  • Confidential guide on numerology and astrology, based of GG33 Public information

  • Contraband Interactive
  • Emulating Dr. Jordan B. Peterson's style in providing life advice and insights.

  • Elijah Ng Shi Yi
  • Advanced software engineer GPT that excels through nailing the basics.

  • rustassistant.com
  • Your go-to expert in the Rust ecosystem, specializing in precise code interpretation, up-to-date crate version checking, and in-depth source code analysis. I offer accurate, context-aware insights for all your Rust programming questions.

  • Emmet Halm
  • Converts Figma frames into front-end code for various mobile frameworks.

  • Alexandru Strujac
  • Efficient thumbnail creator for YouTube videos

  • apappascs
  • 发现市场上最全面,最新的MCP服务器集合。该存储库充当集中式枢纽,提供了广泛的开源和专有MCP服务器目录,并提供功能,文档链接和贡献者。

  • Mintplex-Labs
  • 带有内置抹布,AI代理,无代理构建器,MCP兼容性等的多合一桌面和Docker AI应用程序。

  • modelcontextprotocol
  • 模型上下文协议服务器

  • ShrimpingIt
  • MCP系列GPIO Expander的基于Micropython I2C的操作,源自ADAFRUIT_MCP230XX

  • n8n-io
  • 具有本机AI功能的公平代码工作流程自动化平台。将视觉构建与自定义代码,自宿主或云相结合,400+集成。

  • WangRongsheng
  • 🧑‍🚀 llm 资料总结(数据处理、模型训练、模型部署、 o1 模型、mcp 、小语言模型、视觉语言模型)|摘要世界上最好的LLM资源。

  • open-webui
  • 用户友好的AI接口(支持Ollama,OpenAi API,...)

    Reviews

    3 (1)
    Avatar
    user_G8uqk70E
    2025-04-16

    As a devoted user of traa-mcp, I am thoroughly impressed with its performance and functionality. Opentraa has done a fantastic job creating a robust tool that integrates seamlessly into my workflow. The user experience is intuitive, and the documentation available on their GitHub page is comprehensive. I highly recommend traa-mcp for anyone looking for a reliable solution in this domain.