
YggTorrent MCP Server
A Python MCP server that allows programmatic interaction with YggTorrent, enabling torrent search, details retrieval, and magnet link generation without exposing your Ygg passkey.
README
YggTorrent MCP Server & Wrapper
This repository provides a Python wrapper for the YggTorrent website and an MCP (Model Context Protocol) server to interact with it programmatically. This allows for easy integration of YggTorrent functionalities into other applications or services.
Features
- API wrapper for YggAPI, an unofficial API for YggTorrent.
- Your Ygg passkey is injected locally into the torrent file/magnet link, ensuring it's not exposed externally.
- MCP server interface for standardized communication.
- Search for torrents on YggTorrent (MCP tool).
- Get details for a specific torrent (MCP tool).
- Retrieve magnet links (MCP tool).
- Retrieve torrent files (wrapper only).
- Retrieve torrent categories (MCP resource).
Setup
There are two primary ways to set up and run this project: using a local Python environment or using Docker.
Prerequisites
- An active YggTorrent account with a passkey.
- Python 3.10+ (for local Python setup)
- pip (Python package installer, for local Python setup)
- Docker and Docker Compose (for Docker setup)
Install from PyPI
pip install ygg-torrent-mcp
1. Local Python Environment Setup
-
Clone the repository:
git clone https://github.com/philogicae/ygg-torrent-mcp.git cd ygg-torrent-mcp
-
Create and activate a virtual environment (recommended):
python3 -m venv venv source venv/bin/activate # On Windows, use: venv\Scripts\activate
-
Install dependencies:
pip install -e .
-
Configure environment variables:
Copy the
.env.example
file to.env
and fill in the required variables (Ygg passkey). -
Run the MCP Server:
python -m ygg_torrent
The MCP server will be accessible locally on port 8000.
2. Docker Setup
This project includes a Dockerfile
and docker-compose.yaml
for easy containerization.
-
Clone the repository (if you haven't already):
git clone https://github.com/philogicae/ygg-torrent-mcp.git cd ygg-torrent-mcp
-
Configure environment variables:
Copy the
.env.example
file to.env
and fill in the required variables (Ygg passkey). -
Build and run the Docker container using Docker Compose:
docker-compose -f docker/compose.yaml up --build
This command will build the Docker image (if it doesn't exist) and start the service.
-
Accessing the server:
The MCP server will be accessible on port 8765.
Usage
As Python Wrapper
from ygg_torrent import ygg_api
results = ygg_api.search_torrents('...')
for torrent in results:
print(torrent.name, torrent.size, torrent.seeders)
As MCP Server
from ygg_torrent import ygg_mcp
ygg_mcp.run(transport="sse")
Via MCP Clients
Once the MCP server is running, you can interact with it using any MCP-compatible client. The server will expose endpoints for:
search_torrents
: Search for torrents.get_torrent_details
: Get details of a specific torrent.get_magnet_link
: Get the magnet link for a torrent.
Example for Windsurf
{
"mcpServers": {
"mcp-ygg-torrent": {
"serverUrl": "http://127.0.0.1:8000/sse"
}
}
}
Contributing
Contributions are welcome! Please feel free to submit a Pull Request or open an Issue.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.