transmission-mcp-server

transmission-mcp-server

Enables controlling a Transmission torrent daemon, allowing adding, listing, controlling torrents and checking free space, with support for SOCKS5 proxy for remote access.

Category
访问服务器

README

Transmission MCP Server

A simple MCP server for controlling your Transmission torrent daemon. Supports both direct connection and SOCKS5 proxy for remote access.

Quick Setup

  1. Clone and setup:

    git clone <this-repo>
    cd transmission-mcp-server
    python3 -m venv venv
    source venv/bin/activate
    pip install -r requirements.txt
    
  2. Configure Claude Desktop:

    Copy the configuration from claude-desktop-config.json to your Claude Desktop config file:

    macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

    Important: Update the paths to match your system and use the venv Python: /path/to/transmission-mcp-server/venv/bin/python

    {
      "mcpServers": {
        "transmission": {
          "command": "/path/to/transmission-mcp-server/venv/bin/python",
          "args": ["/path/to/transmission-mcp-server/src/server.py"],
          "env": {
            "TRANSMISSION_HOST": "192.168.1.205",
            "TRANSMISSION_PORT": "9091",
            "TRANSMISSION_USERNAME": "your_username",
            "TRANSMISSION_PASSWORD": "your_password",
            "USE_SOCKS5": "false"
          }
        }
      }
    }
    
  3. For SOCKS5 proxy usage (when away from home): Use the use_socks5: true parameter in your commands to Claude

Environment Variables

  • TRANSMISSION_HOST: IP address of Transmission daemon (default: 192.168.1.205)
  • TRANSMISSION_PORT: Port number (default: 9091)
  • TRANSMISSION_USERNAME: Username for authentication
  • TRANSMISSION_PASSWORD: Password for authentication
  • USE_SOCKS5: Enable SOCKS5 proxy (true/false, default: false)
  • SOCKS5_HOST: SOCKS5 proxy host (default: 127.0.0.1)
  • SOCKS5_PORT: SOCKS5 proxy port (default: 1080)
  • TRANSMISSION_TIMEOUT: Request timeout in seconds (default: 30)

Available Tools

add_torrent

Add a new torrent via magnet link, URL, or local .torrent file.

  • magnet_or_url: Magnet link, torrent file URL, or local .torrent file path
  • download_dir: Optional custom download directory
  • start_torrent: Start torrent immediately after adding (default: true)
  • use_socks5: Use SOCKS5 proxy for this request (default: false)

Local file support: When you provide a local .torrent file path, the server reads the file, base64 encodes it, and sends it to the remote Transmission daemon via the RPC API's metainfo parameter.

control_torrent

Start, stop, or remove torrents.

  • action: "start", "stop", or "remove"
  • torrent_ids: Array of torrent IDs
  • delete_data: Whether to delete local data when removing (default: false)
  • use_socks5: Use SOCKS5 proxy for this request (default: false)

get_free_space

Check available disk space for downloads.

  • path: Optional directory path to check
  • use_socks5: Use SOCKS5 proxy for this request (default: false)

list_torrents

List all torrents with their status, progress, and download directories.

  • use_socks5: Use SOCKS5 proxy for this request (default: false)

get_session_info

Get information about the Transmission daemon session, including version, settings, and statistics.

  • use_socks5: Use SOCKS5 proxy for this request (default: false)

Usage Examples

After setting up Claude Desktop, you can use these commands:

Direct connection (local network):

  • "Show me all my torrents"
  • "Add this magnet link: magnet:?xt=urn:btih:..."
  • "Add this torrent file: /Users/me/Downloads/movie.torrent to /media/Movies"
  • "Stop torrent ID 5"
  • "How much free space do I have?"

Via SOCKS5 proxy (remote access):

  • "Use SOCKS5 to show me all my torrents"
  • "Use SOCKS5 proxy to add this magnet link: magnet:?xt=urn:btih:..."
  • "Use SOCKS5 to stop torrent ID 5"
  • "Use SOCKS5 to get free space"

Network Setup

Direct Connection (Local Network)

Use when your laptop is on the same network as the Transmission server.

SOCKS5 Proxy (Remote Access)

Set up a SOCKS5 tunnel when away from home, then use use_socks5: true in your commands:

# SSH tunnel with SOCKS5
ssh -D 1080 -N user@your-home-server.com

Then tell Claude: "Use SOCKS5 to add this magnet link..."

Troubleshooting

Connection Issues

  • Verify Transmission daemon is running and accessible
  • Check firewall settings on the Transmission server
  • Ensure RPC is enabled in Transmission settings
  • Verify username/password if authentication is required

SOCKS5 Issues

  • Confirm SOCKS5 proxy is running on specified host:port
  • Test SOCKS5 connectivity with another tool first
  • Check if authentication is required for your SOCKS5 proxy

Authentication Issues

  • Verify username/password in environment variables
  • Check if Transmission requires authentication
  • Ensure RPC whitelist includes your client IP

Development

The server is contained in a single file (src/server.py) for simplicity. It uses:

  • httpx for HTTP requests
  • pydantic for configuration management
  • mcp for the Model Context Protocol integration

License

MIT License - see LICENSE file for details.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选