
Mpv Mcp Server
io.github.arijit-gogoi由 GitHub 账号 arijit-gogoi 发布v1.2.0更新于 Oct 24, 2026
Control mpv media player — playback, playlists, YouTube streaming, and downloads.
概览
一个本地 MCP 服务器,让助手控制 mpv 播放器:浏览媒体库、管理播放列表、调节播放、串流 YouTube 并下载曲目。
- 可以做什么
- 控制播放:按路径或搜索词播放、暂停、继续、停止、跳转,以及获取或设置音量与播放状态。浏览与管理媒体库:列出和搜索媒体文件、查看当前播放列表、添加曲目、加载播放列表文件、切换上一首或下一首。从 YouTube 串流与下载,支持追加模式和音频或视频下载。读取并写入曲目元数据,如艺术家、标题、专辑、流派和日期。
- 适用场景
- 适合让助手免手动地操作桌面音乐或视频播放:排队曲目、调节音量、查看当前播放内容,或把 YouTube 音频下载到本地媒体库。
- 运行要求
- 通过 npx 以 stdio 在本地运行,需要 Node.js 22+,以及位于 PATH 或由 MPV_PATH 指定的 mpv 播放器。YouTube 工具需要 yt-dlp;音频下载和元数据工具需要 ffmpeg。可选环境变量用于设置 IPC 套接字路径、媒体目录和下载目录。仅在 Windows 上开发和测试,macOS 与 Linux 支持尚未测试。
安装
在 SourceWeft 中
- 打开 控制台中的 Mpv Mcp Server,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
mpv-mcp-server
MCP server for controlling mpv media player. Browse your music library, control playback, stream from YouTube, and download tracks — all from inside an MCP client like Claude Code.
Prerequisites
- mpv — media player (must be on your PATH, or set
MPV_PATH) - Node.js 22+
- yt-dlp (optional) — required for YouTube streaming and downloading
- ffmpeg (optional) — required for audio extraction, metadata reading (ffprobe), and tagging
Quick Start
Claude Code
Add to your project's .mcp.json:
Or add at user scope (available in all projects):
Claude Desktop
Add to your Claude Desktop config:
With environment overrides
Configuration
All configuration is via environment variables. Everything has sensible defaults.
Tools
Playback
Library
YouTube
YouTube tools require yt-dlp on your PATH. Audio downloads also require ffmpeg.
Metadata
Both tools infer artist/title from the "Artist - Title" filename pattern. Requires ffmpeg (includes ffprobe).
How It Works
The server communicates with mpv via its JSON IPC protocol. On Windows this uses a named pipe, on macOS/Linux a Unix domain socket. If mpv isn't running, the server spawns it automatically in idle mode. The mpv process is detached, so it keeps playing even if the MCP server exits.
Platform Support
Developed and tested on Windows. macOS/Linux support is implemented but untested — issues and PRs welcome!
License
MIT
来源:README.md,提交 3ca7cd7
工具
0版本历史
1- v1.2.0最新Sep 16, 2026
评分
已满足适用检查项的 40%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分
请在仓库或注册中心条目中声明许可证。