Uses Express for server functionality, likely to handle OAuth authentication flows when accessing YouTube content.
Utilizes Google's authentication services (OAuth2) for accessing YouTube content, particularly for private videos, requiring setup through the Google Cloud Console.
Converts YouTube video content into various markdown formats using customizable templates for transcripts, detailed metadata with timestamps, and search results with context highlighting.
Provides tools for interacting with YouTube videos, including extracting video metadata, captions in multiple languages, and converting content to markdown with various templates. Supports search functionality within video captions and flexible authentication methods.
YouTube MCP Server
A Model Context Protocol (MCP) server for interacting with YouTube videos. This server provides tools for extracting video metadata, captions, and converting them to markdown format with various templates.
Features
- Video Metadata: Fetch comprehensive video information
- Caption Extraction: Support for auto-generated and manual captions
- Multiple Languages: Built-in support for English and French
- Template System: Three built-in markdown templates:
- Basic: Simple transcript format
- Detailed: Full metadata with timestamps
- Search: Results highlighting with context
- Search Functionality: Search within video captions
- Flexible Authentication: Supports both API key and OAuth2 authentication
Prerequisites
- Node.js (v16 or higher)
- npm or yarn
- A YouTube Data API key and/or OAuth2 credentials
Installation
- Clone the repository:
- Install dependencies:
- Build the project:
Configuration
Create a .env
file in the root directory with your YouTube credentials:
MCP Configuration
Add the server to your MCP settings file (usually at ~/.config/Code/User/globalStorage/rooveterinaryinc.roo-cline/settings/cline_mcp_settings.json
):
Usage
The server provides the following tools:
1. Get Video Info
2. Get Captions
3. Convert to Markdown
4. List Templates
Dependencies
OAuth2 Setup
For OAuth2 authentication (required for private video access):
- Create a project in the Google Cloud Console
- Enable the YouTube Data API v3
- Create OAuth2 credentials (Web application type)
- Run the authentication script:
- Follow the browser prompts to authorize the application
- Copy the refresh token to your configuration
Customizing Templates
You can add custom templates by modifying the DEFAULT_TEMPLATES
array in src/index.ts
. Templates follow this structure:
License
MIT
Contributing
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
Tools
Enables interaction with YouTube videos by extracting metadata, captions in multiple languages, and converting content to markdown with various templates.
Related MCP Servers
- -securityFlicense-qualityA server for downloading, processing, and managing YouTube content with features like video quality selection, format conversion, and metadata extraction.Last updated -JavaScript
- -securityFlicense-qualityEnables extraction of transcript text from YouTube videos by providing the video URL, supporting standard, shortened, and embed URL formats.Last updated -61JavaScript
- -securityFlicense-qualityEnables AI language models to interact with YouTube content through a standardized interface, providing tools for retrieving video information, transcripts, channel analytics, and trend analysis.Last updated -6,57342JavaScript
- AsecurityAlicenseAqualityA Model Context Protocol server that enables access to YouTube video content through transcripts, translations, summaries, and subtitle generation in various languages.Last updated -51PythonMIT License