Sponsored by Deepsite.site

💾 Synology MCP Server

Created By
atom2ueki8 months ago
💾 Model Context Protocol (MCP) server for Synology NAS - Enables AI assistants (Claude, Cursor, Continue) to manage files, downloads, and system operations through secure API integration. Features Docker deployment, auto-authentication, and comprehensive file system tools.
Content

💾 Synology MCP Server

Synology MCP Server

A Model Context Protocol (MCP) server for Synology NAS devices. Enables AI assistants to manage files and downloads through secure authentication and session management.

🚀 Quick Start with Docker

1️⃣ Setup Environment

# Clone repository
git clone https://github.com/atom2ueki/mcp-server-synology.git
cd mcp-server-synology

# Create environment file
cp env.example .env

2️⃣ Configure .env File

# Required: Synology NAS connection
SYNOLOGY_URL=http://192.168.1.100:5000
SYNOLOGY_USERNAME=your_username
SYNOLOGY_PASSWORD=your_password

# Optional: Auto-login on startup
AUTO_LOGIN=true
VERIFY_SSL=false

3️⃣ Run with Docker

# Build and run
docker-compose up --build

# Most of the case you run detached
docker-compose up -d --build

4️⃣ Alternative: Docker Run

# Build image
docker build -t synology-mcp-server .

# Run container
docker run --env-file .env synology-mcp-server

🔌 MCP Client Setup

🤖 Claude Desktop

Add to your Claude Desktop configuration file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "synology": {
      "command": "docker-compose",
      "args": [
        "-f", "/path/to/your/mcp-server-synology/docker-compose.yml",
        "run", "--rm", "synology-mcp"
      ],
      "cwd": "/path/to/your/mcp-server-synology"
    }
  }
}

🔄 Continue (VS Code Extension)

Add to your Continue configuration (.continue/config.json):

{
  "mcpServers": {
    "synology": {
      "command": "docker-compose",
      "args": [
        "-f", "/path/to/your/mcp-server-synology/docker-compose.yml",
        "run", "--rm", "synology-mcp"
      ],
      "cwd": "/path/to/your/mcp-server-synology"
    }
  }
}

↗️ Cursor

Add to your Cursor MCP settings:

{
  "mcpServers": {
    "synology": {
      "command": "docker-compose",
      "args": [
        "-f", "/path/to/your/mcp-server-synology/docker-compose.yml",
        "run", "--rm", "synology-mcp"
      ],
      "cwd": "/path/to/your/mcp-server-synology"
    }
  }
}

💻 Codeium

For Codeium's MCP support:

{
  "mcpServers": {
    "synology": {
      "command": "docker-compose",
      "args": [
        "-f", "/path/to/your/mcp-server-synology/docker-compose.yml",
        "run", "--rm", "synology-mcp"
      ],
      "cwd": "/path/to/your/mcp-server-synology"
    }
  }
}

🐍 Alternative: Direct Python Execution

If you prefer not to use Docker, you can run the server directly:

{
  "mcpServers": {
    "synology": {
      "command": "python",
      "args": ["main.py"],
      "cwd": "/path/to/your/mcp-server-synology",
      "env": {
        "SYNOLOGY_URL": "http://192.168.1.100:5000",
        "SYNOLOGY_USERNAME": "your_username",
        "SYNOLOGY_PASSWORD": "your_password",
        "AUTO_LOGIN": "true"
      }
    }
  }
}

💻 Local Development Setup

# Install dependencies
pip install -r requirements.txt

# Run directly
python main.py

🛠️ Available MCP Tools

🔐 Authentication

  • synology_status - Check authentication status and active sessions
  • synology_login - Authenticate with Synology NAS (conditional)
  • synology_logout - Logout from session (conditional)

📁 File System Operations

  • list_shares - List all available NAS shares
  • list_directory - List directory contents with metadata
    • path (required): Directory path starting with /
  • get_file_info - Get detailed file/directory information
    • path (required): File path starting with /
  • search_files - Search files matching pattern
    • path (required): Search directory
    • pattern (required): Search pattern (e.g., *.pdf)
  • create_file - Create new files with content
    • path (required): Full file path starting with /
    • content (optional): File content (default: empty string)
    • overwrite (optional): Overwrite existing files (default: false)
  • create_directory - Create new directories
    • folder_path (required): Parent directory path starting with /
    • name (required): New directory name
    • force_parent (optional): Create parent directories if needed (default: false)
  • delete - Delete files or directories (auto-detects type)
    • path (required): File/directory path starting with /
  • rename_file - Rename files or directories
    • path (required): Current file path
    • new_name (required): New filename
  • move_file - Move files to new location
    • source_path (required): Source file path
    • destination_path (required): Destination path
    • overwrite (optional): Overwrite existing files

📥 Download Station Management

  • ds_get_info - Get Download Station information
  • ds_list_tasks - List all download tasks with status
    • offset (optional): Pagination offset
    • limit (optional): Max tasks to return
  • ds_create_task - Create new download task
    • uri (required): Download URL or magnet link
    • destination (optional): Download folder path
  • ds_pause_tasks - Pause download tasks
    • task_ids (required): Array of task IDs
  • ds_resume_tasks - Resume paused tasks
    • task_ids (required): Array of task IDs
  • ds_delete_tasks - Delete download tasks
    • task_ids (required): Array of task IDs
    • force_complete (optional): Force delete completed
  • ds_get_statistics - Get download/upload statistics

⚙️ Configuration Options

VariableRequiredDefaultDescription
SYNOLOGY_URLYes*-NAS base URL (e.g., http://192.168.1.100:5000)
SYNOLOGY_USERNAMEYes*-Username for authentication
SYNOLOGY_PASSWORDYes*-Password for authentication
AUTO_LOGINNotrueAuto-login on server start
VERIFY_SSLNotrueVerify SSL certificates
DEBUGNofalseEnable debug logging

*Required for auto-login and default operations

📖 Usage Examples

📁 File Operations

✅ Creating Files and Directories

File Creation

// List directory
{
  "path": "/volume1/homes"
}

// Search for PDFs
{
  "path": "/volume1/documents", 
  "pattern": "*.pdf"
}

// Create new file
{
  "path": "/volume1/documents/notes.txt",
  "content": "My important notes\nLine 2 of notes",
  "overwrite": false
}

🗑️ Deleting Files and Directories

File Deletion

// Delete file or directory (auto-detects type)
{
  "path": "/volume1/temp/old-file.txt"
}

// Move file
{
  "source_path": "/volume1/temp/file.txt",
  "destination_path": "/volume1/archive/file.txt"
}

⬇️ Download Management

🛠️ Creating a Download Task

Download Sample

// Create download task
{
  "uri": "https://example.com/file.zip",
  "destination": "/volume1/downloads"
}

// Pause tasks
{
  "task_ids": ["dbid_123", "dbid_456"]
}

🦦 Download Results

Download Result

✨ Features

  • Secure Authentication - RSA encrypted password transmission
  • Session Management - Persistent sessions across multiple NAS devices
  • Complete File Operations - Create, delete, list, search, rename, move files with detailed metadata
  • Directory Management - Recursive directory operations with safety checks
  • Download Station - Complete torrent and download management
  • Docker Support - Easy containerized deployment
  • Multi-Client Support - Works with Claude, Continue, Cursor, Codeium and more
  • Error Handling - Comprehensive error reporting and recovery
Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
Amap Maps高德地图官方 MCP Server
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
Y GuiA web-based graphical interface for AI chat interactions with support for multiple AI models and MCP (Model Context Protocol) servers.
Serper MCP ServerA Serper MCP Server
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
CursorThe AI Code Editor
DeepChatYour AI Partner on Desktop
WindsurfThe new purpose-built IDE to harness magic
Tavily Mcp
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
ChatWiseThe second fastest AI chatbot™
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright McpPlaywright MCP server