home / mcp / mcp server for binge-watch

MCP Server for Binge-watch

Provides search and playback access to streaming sources for binge-watching with AI-assisted discovery and Xiaomi TV playback support.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "aahl-mcp-vods": {
      "url": "http://0.0.0.0:8821/mcp",
      "headers": {
        "LUNA_BASE_URL": "<LUNA_BASE_URL>",
        "LUNA_PASSWORD": "<LUNA_PASSWORD>",
        "LUNA_USERNAME": "<LUNA_USERNAME>",
        "MITV_LIST_CFG": "客厅电视:192.168.1.11;主卧电视:192.168.1.12",
        "MITV_LOCAL_IP": "<MITV_LOCAL_IP>",
        "MOON_BASE_URL": "<MOON_BASE_URL>",
        "TVBOX_LIST_CFG": "<TVBOX_LIST_CFG>",
        "TVBOX_LOCAL_IP": "<TVBOX_LOCAL_IP>",
        "VOD_CONFIG_URL": "<VOD_CONFIG_URL>",
        "MAX_SEARCH_SITES": "<MAX_SEARCH_SITES>",
        "SEARCH_CACHE_TTL": "<SEARCH_CACHE_TTL>"
      }
    }
  }
}

This MCP server enables search and playback of binge-worthy content by providing access to streaming addresses for AI-assisted discovery, and it supports direct playback on Xiaomi TVs for a seamless viewing experience.

How to use

You connect an MCP client to this server to discover shows and retrieve playback URLs. Use the HTTP MCP endpoint when available to fetch sources and start playback on your preferred device. If you run the local, AI-assisted server, you can also target Xiaomi TV devices for direct playback using the configured network settings.

How to install

Prerequisites: ensure you have a runtime environment for the MCP server. You can run the server via uvx or Docker, as shown below.

Option 1 — uvx (local runtime) setup: create a configuration that launches the MCP server using uvx.

{
  "mcpServers": {
    "vods": {
      "command": "uvx",
      "args": ["mcp-vods"],
      "env": {
        "MITV_LIST_CFG": "客厅电视:192.168.1.11"
      }
    }
  }
}

Option 2 — Docker deployment: pull the compose file and run the container, exposing the MCP endpoint.

mkdir /opt/mcp-vods
cd /opt/mcp-vods
wget https://raw.githubusercontent.com/aahl/mcp-vods/refs/heads/main/docker-compose.yml
docker-compose up -d
```
```yaml
{
  "mcpServers": {
    "vods": {
      "url": "http://0.0.0.0:8821/mcp" # Streamable HTTP
    }
  }
}

Option 3 — Home Assistant OS Add-on: access the add-on repository to install and configure the MCP server within Home Assistant OS.

Quick start commands for integrating with various assistants and tools are provided to simplify adding the MCP server to supporting platforms.

Steps to start using the server after setup include configuring your MCP client to point at the appropriate HTTP URL or starting the local runtime with the provided environment variables.

Additional configuration and environment variables

The following environment variables are supported to tailor the MCP server behavior. Some are for out-of-the-box use, while others enable integration with deployed LunaTV or MoonTV services, or Xiaomi TV devices.

Environment variables overview

Unconfigured, ready-to-use options (out-of-the-box): - VOD_CONFIG_URL: Remote configuration URL for LunaTV/MoonTV subscriptions (optional; built-in default) - SEARCH_CACHE_TTL: Cache duration for search results (optional; default is 5 minutes) - MAX_SEARCH_SITES: Maximum number of hosts to search in a single query (optional; default is 10)

Deployed LunaTV/MoonTV integration options (if you already have MoonTV/LunaTV running): - MOON_BASE_URL: Address of the MoonTV service (optional) - LUNA_BASE_URL: Address of the LunaTV service (optional) - LUNA_USERNAME: LunaTV username (optional) - LUNA_PASSWORD: LunaTV password (optional)

Xiaomi TV and other Android TV playback options: - MITV_LOCAL_IP: Local IP of a single Xiaomi TV (optional) - MITV_LIST_CFG: Configuration for multiple Xiaomi TVs, format like: 客厅电视:192.168.1.11;主卧电视:192.168.1.12 (optional)

Other Android TV devices (non-Mi TV) playback options: - TVBOX_LOCAL_IP: Local IP of a single Android TV device (optional) - TVBOX_LIST_CFG: Configuration for multiple Android TV devices, format like: 客厅电视:192.168.1.11;主卧电视:192.168.1.12 (optional)

Notes and security considerations

Ensure your network is secure when exposing the MCP endpoint. Use strong credentials for any LunarTV/LunaTV integrations and manage access to the local network devices to prevent unauthorized playback.

Tools and endpoints

This server provides search and playback capabilities, integrations with LunaTV/MoonTV services, and playback to Xiaomi TVs or other Android TV devices.

Available tools

SearchShow

Search across configured sources to find shows and their playback URLs

PlayUrl

Resolve and return playable streaming URLs for selected content