Youtube MCP Server
Youtube MCP 服务器
关于
该服务器是 Youtube API 和 AI 助手之间的桥梁,基于模型上下文协议。
Related MCP server: YouTube Tools MCP Server
什么是 MCP?
模型上下文协议 (MCP) 是一个允许 AI 应用(例如 Claude Desktop)连接到外部工具和数据源的系统。它为 AI 助手提供了一种清晰、安全的方式,使其能够使用本地服务和 API,同时保持用户的控制权。
这个服务器是做什么的?
[x] 下载指定视频的隐藏字幕
实际用例
[x] 创建视频摘要
先决条件
安装
uv tool install git+https://github.com/sparfenyuk/mcp-youtube[!NOTE] 如果您已经安装了服务器,则可以使用
uv tool upgrade --reinstall命令进行更新。
[!NOTE] 如果要删除服务器,请使用
uv tool uninstall mcp-youtube命令。
配置
Claude桌面配置
配置 Claude Desktop 以识别 Youtube MCP 服务器。
打开Claude桌面配置文件:
在 MacOS 中,配置文件位于
~/Library/Application Support/Claude/claude_desktop_config.json在 Windows 中,配置文件位于
%APPDATA%\Claude\claude_desktop_config.json
**注意:**您还可以在 Claude Desktop 应用程序的设置中找到 claude_desktop_config.json
添加服务器配置
{ "mcpServers": { "mcp-youtube": { "command": "mcp-youtube", } } } }
发展
入门
克隆存储库
安装依赖项
uv sync运行服务器
uv run mcp-youtube --help
可以将工具添加到src/mcp_youtube/tools.py文件中。
如何添加新工具:
创建一个继承自 ToolArgs 的新类
class NewTool(ToolArgs): """Description of the new tool.""" pass该类的属性将用作该工具的参数。类的文档字符串将用作工具的描述。
为新类实现 tool_runner 函数
@tool_runner.register async def new_tool(args: NewTool) -> t.Sequence[TextContent | ImageContent | EmbeddedResource]: pass该函数应返回 TextContent、ImageContent 或 EmbeddedResource 的序列。该函数应为异步函数,并接受新类的单个参数。
完成!重启客户端,新工具就可以使用了。
验证可以通过 Claude Desktop 或直接运行工具来完成。
在检查器中调试服务器
MCP 检查器是一款使用精美 UI 帮助调试服务器的工具。要运行它,请使用以下命令:
npx @modelcontextprotocol/inspector uv run mcp-youtube故障排除
消息“无法连接到 MCP 服务器 mcp-youtube”
如果您在 Claude Desktop 中看到消息“无法连接到 MCP 服务器 mcp-youtube”,则表示服务器配置不正确。
请尝试以下操作:
在配置文件中使用
mcp-youtube二进制文件的完整路径
Available Tools
1 toolDownloadClosedCaptionsC
Download closed captions from YouTube video.
| Name | Required | Description | Default |
|---|---|---|---|
| video_url | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. While 'download' implies a read operation, it doesn't specify authentication requirements, rate limits, output format, error conditions, or whether it modifies any state. This leaves significant gaps in understanding the tool's behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely concise at just one sentence with no wasted words. It's front-loaded with the core purpose and contains no unnecessary information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with no annotations, no output schema, and 0% schema description coverage, the description is insufficient. It doesn't explain what format the captions are returned in, whether authentication is needed, or any error handling. The minimal description leaves too many questions unanswered for effective use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema description coverage is 0%, and the description doesn't provide any information about the single parameter beyond what's implied by the tool name. No details about the video_url format, validation rules, or examples are given, leaving the parameter poorly documented.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('download') and resource ('closed captions from YouTube video'), making the purpose immediately understandable. However, with no sibling tools mentioned, there's no opportunity to differentiate from alternatives, which prevents a perfect score.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives, prerequisites, or limitations. It simply states what the tool does without contextual usage information.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
1 tool update
v1.0.0- Added
DownloadClosedCaptions
TDQS
Scored across 1 tool
With only one tool, there is no possibility of confusion or overlap between tools. The tool has a single, clear purpose that is distinct by default.
The single tool name follows a clear verb_noun pattern (DownloadClosedCaptions), and with no other tools, consistency is inherently perfect. There are no deviations or mixed conventions to evaluate.
A single tool for a YouTube server is too few for the apparent scope, as YouTube involves many operations like searching videos, getting metadata, or managing playlists. This feels thin and incomplete for the domain.
The tool surface is severely incomplete for a YouTube server. It only covers downloading closed captions, with no support for core YouTube functionalities such as video search, retrieval, or interaction, leading to significant gaps and agent failures.
Maintenance
Related MCP Connectors
YouTube transcripts, search, channel/playlist listings and upload tracking for AI agents.
YouTube transcripts, video search, chapters and extractive summaries. No YouTube API key, no LLM.
1Transcripts of YouTube videos, channels, playlists and searches; AI transcription when no captions.
Your YouTube library in Claude, ChatGPT and Cursor: transcripts, breakdowns, summaries, search.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables AI assistants to analyze and summarize YouTube videos by extracting captions, subtitles, and comprehensive metadata including title, description, and duration in multiple languages.127 npm62MIT
- AlicenseBqualityDmaintenanceEnables AI assistants to search YouTube videos using the official YouTube Data API v3, extract full video transcripts in multiple languages, and store/retrieve video summaries using a local database.4MIT
- AlicenseAqualityCmaintenanceConnect AI assistants to YouTube: search, transcripts, metadata, and more.1980 npm6MIT
- AlicenseNot gradedqualityDmaintenanceExtracts captions, metadata, and descriptions from YouTube videos to enable AI assistants to summarize their content.6 npmMIT