convez.ai
MCP ServerIntegração & APIsIntermediário
tulaman

YouTube Watch Later MCP

tulaman/youtube-watchlater-mcp

Acesse Watch Later do YouTube sem OAuth nem APIs restritivas

Ver no GitHub
InicialPluginScore · de 0 a 100

Servidor MCP que acessa sua playlist privada Watch Later do YouTube usando yt-dlp e cookies do navegador. Contorna a limitação da YouTube Data API (que não expõe Watch Later) através de autenticação por browser. Inclui ferramentas para listar vídeos e baixar legendas.

Instalação

$npx convez-ai tulaman/youtube-watchlater-mcp

1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.

Métricas

Estrelas
1
Forks
0
Acompanhando
0
Saúde
42%
Último commit
há 8 meses
Versão
—
Issues abertas
0
Contribuidores
1

Casos de uso

  • Sincronizar fila de vídeos Watch Later com AI assistants
  • Extrair legendas de vídeos salvos para análise
  • Integrar playlist privada em automações pessoais

Veredito

Solução pragmática para um problema real: a YouTube Data API nunca vai expor Watch Later. A abordagem via yt-dlp e cookies é confiável, mas exige yt-dlp instalado localmente e navegador autenticado na máquina. Bom para automações pessoais e assistentes locais.

README

A tradução para o português deste README ainda está na fila.

youtube-watchlater-mcp

MCP server for fetching your YouTube Watch Later playlist via yt-dlp.

Why This Exists

The YouTube Watch Later playlist is invisible to the YouTube Data API.

Most YouTube MCP servers and integrations use the official YouTube Data API v3 with OAuth authentication. This works well for public playlists, subscriptions, search, and liked videos — but Watch Later is a special private playlist (WL) that Google has explicitly excluded from the API. Even with full OAuth scopes and a valid token, the API returns an empty result or a 403 Forbidden error for this playlist.

This means:

  • OAuth-based MCPs cannot access Watch Later — the endpoint simply does not exist in the API.
  • Scraping the YouTube web UI requires managing session cookies, handling anti-bot measures, and is fragile against layout changes.
  • yt-dlp with browser cookies is the only reliable approach: it reads the authentication cookies that your browser already holds from your active YouTube login, and uses them to fetch the playlist directly — exactly as your browser would.

This server wraps that mechanism as an MCP tool so AI assistants can read your Watch Later queue without you needing API keys, OAuth flows, or exposing credentials.

Requirements

  • Node.js 18+
  • yt-dlp installed and available on $PATH
  • YouTube account logged in to a browser on your machine

Installation

1. Install yt-dlp:

# macOS
brew install yt-dlp

# Linux
sudo curl -L https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp -o /usr/local/bin/yt-dlp
sudo chmod a+rx /usr/local/bin/yt-dlp

# Windows (winget)
winget install yt-dlp

2. Install Node.js dependencies:

npm install

Running

npm start

The server communicates over stdio and is intended to be connected to an MCP host (e.g. Claude Desktop), not run directly in a browser.

Claude Desktop Setup

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "youtube-watchlater": {
      "command": "node",
      "args": ["/path/to/youtube-watchlater-mcp/server.mjs"]
    }
  }
}

Tool: get_watch_later

Returns videos from your Watch Later playlist.

ParameterTypeDefaultDescription
browserchrome | brave | edge | firefoxchromeBrowser to read YouTube cookies from
limitnumber (1–500)50Number of videos to return
profilestring—Browser profile name, e.g. "Default" or "Profile 1"

Example response:

{
  "items": [
    {
      "videoId": "dQw4w9WgXcQ",
      "title": "Never Gonna Give You Up",
      "url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
      "channel": "Rick Astley"
    }
  ]
}

Tool: get_subtitles

Downloads auto-generated subtitles for a YouTube video and returns the VTT content.

ParameterTypeDefaultDescription
videostring—YouTube video URL or bare video ID (e.g. dQw4w9WgXcQ)
langstring"en"Subtitle language code, e.g. "en" or "ru"
browserchrome | brave | edge | firefoxchromeBrowser to read YouTube cookies from
profilestring—Browser profile name, e.g. "Default" or "Profile 1"

Example response:

{
  "lang": "en",
  "videoId": "dQw4w9WgXcQ",
  "subtitles": "WEBVTT\n..."
}

How It Works

The server calls yt-dlp --cookies-from-browser <browser> --flat-playlist --dump-json against the WL playlist. Cookies are read directly from the local browser — no tokens or passwords are transmitted anywhere.

Ver o original no GitHub

Bom para

Relacionados