youtube-playlists-mcp
by jeromeberg
README.md
# YouTube Playlists MCP

A simple MCP server to manage YouTube playlists.
## Setup
### Credentials
1. Go to [Google Cloud Console](https://console.cloud.google.com/) and create/select a project
2. Enable the **YouTube Data API v3** (APIs & Services > Library)
3. Configure the OAuth consent screen (APIs & Services > OAuth consent screen)
- In **Data Access**, add the `youtube` and `youtube.force-ssl` scopes
- In **Audience**, add your Google account email as a test user
4. Create OAuth 2.0 credentials (APIs & Services > Credentials > Create Credentials > OAuth client ID)
- Application type: **Web app**
- Add `http://localhost:3000/oauth2` as an authorized redirect URI
5. Download the JSON file and save it as `credentials.json` in the project root
### Build
```bash
npm install
npm run build
```
### Authenticate
Run the server once to sign in with your Google account.
```bash
node dist/index.js
```
Tokens are saved to `tokens.json` for future runs.
### Configure Claude
Add to `~/Library/Application Support/Claude/claude_desktop_config.json`:
```json
{
"mcpServers": {
"youtube-playlists-mcp": {
"command": "node",
"args": ["/absolute/path/to/youtube-playlists-mcp/dist/index.js"]
}
}
}
```
## Tools
| Tool | Description |
|------|-------------|
| `list_playlists` | List all playlists with ID, title, and video count |
| `get_playlist_videos` | Get all videos in a playlist |
| `add_video_to_playlist` | Add video to playlist by video ID |
| `move_video` | Move video from one playlist to another |
| `remove_video_from_playlist` | Remove video from playlist |
## Notes
- "Watch Later" is not supported due to a YouTube API limitation
- The server authenticates on startup and automatically refreshes tokens when they expire
- If authentication doesn't work in Firefox, try a Chromium-based browser
This server cannot be deployed
Maintenance
ActivityStale
ResponsivenessNo issues