MCP Hub
Back to servers

Video URL Analyzer

Analyze YouTube/TikTok/Instagram videos: transcripts, AI insights, tutorial extraction

Registry
Stars
1
Forks
1
Updated
Apr 19, 2026
Validated
May 9, 2026

Quick Install

uvx video-url-analyzer-mcp
Video URL Analyzer MCP

Video URL Analyzer MCP

MCP server to analyze YouTube, TikTok & Instagram videos from URL — transcripts, AI insights, tutorial extraction

PyPI MCP MIT Gemini Python 3.10+ Security Hardened Platform

Features · Quick Start · Tools · Usage · Security · العربية


What is This?

Video URL Analyzer MCP is a Model Context Protocol (MCP) server that lets Claude (or any MCP-compatible AI) analyze videos from YouTube, TikTok, and Instagram — just paste a URL. Powered by Google's Gemini API with full audio + visual analysis, it extracts transcripts, provides AI-powered insights, and can even extract executable tutorial steps.

Features

Features — Analyze, Transcript, Ask

  • YouTube Analysis — Direct analysis via Gemini API (no download needed)
  • TikTok & Instagram — Async job pattern with yt-dlp download + Gemini Files API
  • Full Audio + Visual — Analyzes both video frames AND audio/speech
  • 6 Tools — analyze, transcript, Q&A, watch & analyze, execute tutorials, check jobs
  • Bilingual — Supports Arabic and English prompts and responses
  • Async Jobs — Background processing prevents Claude Desktop timeout crashes
  • Security Hardened — URL allowlist, SSRF protection, command injection prevention, path traversal blocking
  • Zero-Config Installuvx video-url-analyzer-mcp and you are running

Supported Platforms

PlatformMethodSpeed
YouTubeDirect Gemini analysis — no download neededInstant
TikToktikwm.com API (fast) → yt-dlp fallback~8s
InstagramPage scrape via curl_cffi (fast) → yt-dlp fallback~10s

YouTube videos are analyzed directly through Gemini's native video understanding — zero download, zero upload, maximum speed.


Quick Start

Option 1: uvx (Recommended)

Requires uv.

Claude Desktop -- add to claude_desktop_config.json:

{
  "mcpServers": {
    "video-analyzer": {
      "command": "uvx",
      "args": ["video-url-analyzer-mcp"],
      "env": {
        "GEMINI_API_KEY": "your_key"
      }
    }
  }
}

Claude Code:

claude mcp add video-analyzer -s user -e GEMINI_API_KEY=your_key -- uvx video-url-analyzer-mcp

Cursor / VS Code -- add to .cursor/mcp.json or .vscode/mcp.json:

{
  "servers": {
    "video-analyzer": {
      "command": "uvx",
      "args": ["video-url-analyzer-mcp"],
      "env": { "GEMINI_API_KEY": "your_key" }
    }
  }
}

Windsurf -- add to ~/.codeium/windsurf/mcp_config.json:

{
  "mcpServers": {
    "video-analyzer": {
      "command": "uvx",
      "args": ["video-url-analyzer-mcp"],
      "env": { "GEMINI_API_KEY": "your_key" }
    }
  }
}

Option 2: pip install

pip install video-url-analyzer-mcp

Option 3: From source

git clone https://github.com/u2n4/video-url-analyzer-mcp.git
cd video-url-analyzer-mcp
pip install -e .

Tools

ToolWhat it does
analyze_videoFull audio + visual analysis with custom prompts. Uses Gemini for state-of-the-art multimodal understanding.
get_transcriptExtract timestamped transcript with speaker identification. Supports 100+ languages via auto-detection.
ask_about_videoAsk any question — "How many people appear?", "What brand is shown at 0:45?", "Summarize the main argument."
watch_and_analyzeExtract tutorial steps, shell commands, code snippets, and file paths from technical videos.
execute_tutorial_stepsReview extracted steps safely, then execute with confirmation. Sandboxed with command & path validation.
check_analysis_jobPoll background job status for TikTok/Instagram async downloads.

How It Works

YouTube — Synchronous: URL is sent directly to Gemini API for instant analysis (no download).

TikTok & Instagram — Asynchronous: Video is downloaded via yt-dlp, uploaded to Gemini Files API, analyzed, then cleaned up. Returns a job_id immediately — poll with check_analysis_job.


Usage Examples

# Full video analysis
analyze_video("https://www.youtube.com/watch?v=dQw4w9WgXcQ")

# Custom analysis prompt
analyze_video("https://www.tiktok.com/@user/video/123",
              prompt="List every product shown and estimate prices")

# Multilingual transcript extraction
get_transcript("https://www.instagram.com/reel/ABC123/", lang="ar")

# Ask specific questions about video content
ask_about_video("https://youtu.be/abc",
                question="What programming language is used in the tutorial?")

# Watch & build — extract tutorial steps
watch_and_analyze("https://www.youtube.com/watch?v=tutorial123")

Architecture

Architecture Diagram

ComponentRole
Gemini APIMultimodal model — full audio + visual understanding in a single pass
FastMCP 3.xMCP protocol framework over stdio transport
yt-dlp + curl_cffiVideo download with Chrome browser impersonation to bypass anti-bot
tikwm.com APITikTok fast-path fallback when yt-dlp is WAF-blocked
Background JobsAsync threading for TikTok/Instagram to prevent Claude Desktop timeouts
video-url-analyzer-mcp/
├── pyproject.toml                    # Package metadata & dependencies
├── src/
│   └── video_url_analyzer_mcp/
│       ├── __init__.py               # Package init + version
│       ├── __main__.py               # python -m support
│       └── server.py                 # Main MCP server (all 6 tools)
├── .env.example                      # Environment variable template
├── llms.txt                          # AI-readable project summary
├── llms-install.md                   # AI-readable install guide
├── CONTRIBUTING.md
├── CHANGELOG.md
└── LICENSE

Platform Detection

URLs are automatically routed to the correct pipeline:

  • YouTube: youtube.com, youtu.be, youtube.com/shorts/
  • TikTok: tiktok.com, vm.tiktok.com, vt.tiktok.com
  • Instagram: instagram.com/reels/, instagram.com/reel/, instagram.com/p/

Security

This server has been hardened against a comprehensive threat model:

LayerProtection
SSRFURL allowlist — only YouTube, TikTok, Instagram domains accepted. Private IPs, localhost, file:// blocked.
Command Injectionshell=False + shlex.split(). Dangerous command blocklist (rm -rf, reverse shells, eval, pipe-to-shell).
Path Traversal25+ sensitive path patterns blocked (.ssh, .aws, .env, system dirs, AppData).
TLSFull certificate validation on all downloads.
Browser CookiesOpt-in only via VIDEO_ANALYZER_COOKIES=true. Disabled by default.
Download SizeHard limit of 100 MB per video.
DoS ProtectionMax 10 concurrent background jobs. Auto-expiry after 1 hour. Storage cap of 200 analyses.
Schema ValidationGemini JSON responses validated before execution. Response size capped at 500K chars.
DependenciesAll versions pinned in pyproject.toml.

Configuration

VariableDescriptionDefault
GEMINI_API_KEYGoogle Gemini API key (required)
ANALYSES_DIRDirectory to store analysis results./analyses
VIDEO_ANALYZER_COOKIESEnable browser cookies for yt-dlpfalse

Tech Stack

TechnologyPurpose
google-genaiGoogle Gemini API SDK
FastMCPMCP protocol framework
yt-dlpVideo downloader
curl_cffiBrowser impersonation (TLS fingerprint)
python-dotenvEnvironment variable loading

Troubleshooting

IssueSolution
GEMINI_API_KEY not setCreate .env file or pass via environment variable
TikTok download failstikwm.com fallback activates automatically. Ensure curl_cffi is installed.
Instagram download failspip install curl_cffi for browser impersonation support
ENOENT on WindowsUse uvx video-url-analyzer-mcp as the command
Claude Desktop timeoutTikTok/Instagram run in background — use check_analysis_job(job_id) to poll
Python not foundInstall Python 3.10+ from python.org

Contributing

See CONTRIBUTING.md for guidelines.

License

MIT — see LICENSE.

Support

If you find this useful, please star this repository!


Made with ❤️ in the Eastern Province of Saudi Arabia.


العربية

خادم تحليل الفيديو

خادم تحليل الفيديو بالذكاء الاصطناعي

خادم MCP لتحليل الفيديو باستخدام Google Gemini — احدث واقوى نموذج ذكاء اصطناعي متعدد الوسائط من جوجل.

المميزات

الاداةالوصف
analyze_videoتحليل شامل للصوت والصورة مع دعم الاوامر المخصصة
get_transcriptاستخراج النص المنطوق مع الطوابع الزمنية — يدعم +100 لغة
ask_about_videoاسال اي سؤال عن محتوى الفيديو
watch_and_analyzeاستخراج خطوات الشروحات التقنية والاوامر والاكواد
execute_tutorial_stepsمراجعة وتنفيذ الخطوات المستخرجة بامان

المنصات المدعومة

المنصةالسرعة
يوتيوبفوري — تحليل مباشر بدون تحميل
تيك توك~8 ثواني — واجهة tikwm.com السريعة
انستاجرام~10 ثواني — استخراج مباشر من الصفحة

التثبيت السريع

git clone https://github.com/u2n4/video-url-analyzer-mcp.git
cd video-url-analyzer-mcp
pip install -e .

الامان

الخادم محمي ضد:

  • SSRF — قائمة بيضاء للنطاقات المسموحة فقط
  • حقن الاوامر — حظر الاوامر الخطيرة + تنفيذ بدون shell
  • اختراق المسارات — حظر 25+ مسار حساس
  • حماية من الحمل الزائد — حد اقصى 10 مهام متزامنة

الحصول على مفتاح API

  1. اذهب الى Google AI Studio
  2. انشئ مفتاح API مجاني
  3. ضعه في ملف .env

Reviews

No reviews yet

Sign in to write a review