Skip to main content
Glama
mohamdben-yahia

YouTube MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MCP_AUTH_KEYNoSecret token used to authenticate access when the server is hosted over SSE/HTTP. If unset or set to 'auto', a secure token is generated and displayed in the logs.
YOUTUBE_API_KEYNoYour YouTube Data API v3 key. Required for YouTube Data API calls; optional for transcript and RSS features.
YOUTUBE_API_KEYSNoComma-separated list of YouTube API keys for automatic quota rotation, e.g. key1,key2,key3.
YOUTUBE_CACHE_DIRNoDirectory path where the persistent response cache is stored.
YOUTUBE_CACHE_TTLNoTime-to-live duration for cached responses before they are considered stale.
YOUTUBE_CACHE_ENABLEDNoSet to 'true' to enable persistent disk-based caching, or 'false' to disable it.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
search_videosA

Search YouTube for videos, channels, or playlists.

Args: query: Search keywords or query string. max_results: Number of results to return (1 to 50, default 10). search_type: Type of resource to search for ('video', 'channel', 'playlist'). order: Sort order ('relevance', 'date', 'rating', 'viewCount', 'title'). published_after: RFC 3339 formatted date-time string (e.g. '2024-01-01T00:00:00Z'). region_code: ISO 3166-1 alpha-2 country code (e.g. 'US', 'FR'). raw: If True, returns unaltered raw YouTube Data API response.

search_channelsA

Search YouTube specifically for channels matching a query or niche, enriched with subscribers, views, and video counts.

Ideal for creator discovery, niche research, and competitor mapping.

Args: query: Topic or niche keywords (e.g. 'ai automation', 'budget travel', 'investing for beginners'). max_results: Number of channels to return (1 to 50, default 10). order: Ranking order ('relevance', 'videoCount', 'viewCount', 'rating'). region_code: ISO 3166-1 alpha-2 country code (e.g. 'US', 'GB', 'CA').

get_video_detailsA

Retrieve metadata, views, likes, duration, and tags for one or more YouTube videos.

Args: video_ids: List of 11-character video IDs or URLs (up to 50 IDs). raw: If True, returns unaltered raw YouTube Data API response.

get_video_transcriptA

Retrieve full video transcripts or subtitles without requiring an API key.

Args: video_id_or_url: YouTube video ID or full URL (e.g., 'dQw4w9WgXcQ' or 'https://youtu.be/...'). languages: Language priority list (e.g., ['en', 'es']). Defaults to ['en']. format: Output format: 'text' (concatenated string), 'timestamped' (lines with [hh:mm:ss]), or 'json' (array of segment objects). start_seconds: Optional start timestamp to filter segments. end_seconds: Optional end timestamp to filter segments.

get_channel_detailsA

Retrieve channel information, subscriber counts, total views, and uploads playlist ID.

Provide at least one identifier: channel_id (e.g. 'UC...'), for_handle (e.g. '@mkbhd'), or for_username.

Args: channel_id: YouTube Channel ID (e.g., 'UCBJycsmduvYEL83R_U4JriQ'). for_handle: YouTube Channel handle with or without '@' (e.g., '@mkbhd' or 'veritasium'). for_username: YouTube channel legacy username. raw: If True, returns unaltered raw YouTube Data API response.

get_playlist_itemsA

Retrieve video items contained within a YouTube playlist.

Args: playlist_id: The ID of the playlist (e.g. 'PLrAXtmErZgOdP_8GzKt233nyGH51l50DH' or channel uploads ID). max_results: Number of items to retrieve (up to 50, default 20). page_token: Token for retrieving next page of results. raw: If True, returns unaltered raw YouTube Data API response.

get_video_commentsA

Retrieve top-level comment threads and discussions for a video.

Args: video_id: Video ID or URL to fetch comments for. max_results: Number of comments to retrieve (up to 100, default 20). order: Sort order: 'relevance' (most popular) or 'time' (newest first). page_token: Token for retrieving next page of comments. raw: If True, returns unaltered raw YouTube Data API response.

scout_niche_channelsA

Launch a multi-niche discovery campaign to identify and rank top YouTube channels.

Useful for creator scouting, influencer marketing campaigns, competitor analysis, and sponsorship outreach.

Args: niches: List of niche keywords/topics (e.g. ['ai automation', 'saas tools', 'b2b sales']). min_subscribers: Minimum subscriber threshold (e.g. 5000 or 10000 for micro-influencers). max_subscribers: Optional maximum subscriber threshold (e.g. 100000). min_videos: Minimum video count to filter out inactive accounts (default: 1). region_code: ISO 3166-1 alpha-2 country code (e.g. 'US', 'GB', 'FR'). channels_per_niche: Number of top channels to return per niche (default: 10). sort_by: Ranking attribute: 'subscribers' (default), 'views', 'videos', or 'avg_views'.

get_trending_nichesA

Discover real-time trending topics, breakout niches, and viral videos right now.

Analyzes YouTube's official real-time trending chart to extract top rising tags, recurring title keywords, and breakout creators dominating the algorithm.

Args: region_code: Country code (default 'US', e.g. 'GB', 'CA', 'DE', 'FR', 'IN'). category: Niche category ('all', 'tech', 'gaming', 'education', 'howto', 'entertainment', 'news', 'music', 'sports') or numeric ID. max_results: Number of trending videos to analyze (up to 50, default 25). raw: If True, returns unaltered raw YouTube Data API response.

audit_channel_strategyA

Reverse-engineer any YouTube channel's content strategy and monetization model.

Analyzes upload cadence, view performance distribution, title formulas, monetization links (sponsors, newsletters, affiliate links), and extracts the opening script hook from their top-performing video.

Args: channel_id_or_handle: Channel handle (e.g. '@mkbhd', '@aliabdaal'), channel ID ('UC...'), or username. sample_videos: Number of recent uploads to analyze (3 to 15, default 5).

reverse_engineer_channelA

Perform full end-to-end reverse engineering on any YouTube channel.

Deconstructs upload cadence, view-to-sub engagement ratio, title formulas, the opening 60s script hook of their top video, full monetization funnel, and mines real viewer comments for unmet content requests and pain points. Delivers a step-by-step replication playbook for a new creator to model or compete.

Args: channel_id_or_handle: Channel handle (e.g. '@mkbhd', '@aliabdaal'), channel ID ('UC...'), or username. sample_videos: Number of recent uploads to analyze (3 to 15, default 5). include_audience_gaps: If True, mines the comment section of their top video for unmet viewer needs.

find_viral_outliersA

Identify viral outlier videos that perform dramatically above a channel's normal average.

Discovers breakout video ideas from either a specific creator (e.g. '@creator') or across a broad niche topic (e.g. 'productivity tools') by flagging videos whose views surpass the channel's subscriber/view baseline by 2.5x, 5x, or 10x+.

Args: query: Niche topic keyword or creator handle ('@creator'). min_multiplier: Outlier threshold multiplier (default 2.5 means 2.5x the channel benchmark). published_after: RFC 3339 datetime to filter recent breakouts (e.g. '2024-01-01T00:00:00Z'). max_results: Number of candidates to evaluate (up to 50, default 25).

analyze_audience_sentimentA

Mine video comments to discover audience pain points, questions, and content requests.

Identifies what viewers struggle with, questions the creator missed, topics requested for future videos, and the highest-upvoted comments.

Args: video_id_or_url: YouTube Video ID or full URL. max_comments: Number of top comments to analyze (up to 100, default 100).

compare_channelsA

Perform a head-to-head benchmarking comparison between 2 to 10 competing YouTube channels.

Compares subscriber growth velocity, recent average views, upload cadence, views-to-subscriber efficiency, and highlights category winners.

Args: channel_handles: List of 2 to 10 channel handles (e.g. ['@channel1', '@channel2']) or Channel IDs.

extract_shorts_clipsA

Generate YouTube chapters and extract the top 30-60s viral Shorts/Reels clips from transcripts.

Does NOT require a YouTube API key. Scans spoken transcripts for psychological hook triggers and formats timestamps ready to paste into video descriptions or feed into video editors.

Args: video_id_or_url: YouTube Video ID or full URL. min_duration_seconds: Minimum clip duration for Shorts/Reels (default 20). max_duration_seconds: Maximum clip duration for Shorts/Reels (default 60). max_clips: Maximum number of candidate clips to return (default 5).

blueprint_new_channelA

Conduct a full market research study and launch blueprint for starting a new YouTube channel.

Specifically engineered for beginners and new creators. Validates topic demand, identifies 3-5 realistic mid-sized channels to model (1k-300k subs), discovers proven outlier video topics where smaller channels blew up, mines audience pain points from comments, and provides a ready-to-record 5-video launch roadmap with recommended upload cadence.

Args: niche: The niche/topic you want to launch a channel in (e.g. 'ai automation', 'budget travel', 'personal finance for teens'). target_audience: Optional description of who your videos are for (e.g. 'complete beginners', 'busy moms'). region_code: Geographic market code (default 'US', e.g. 'GB', 'CA', 'DE').

find_breakout_growth_channelsA

Find modern breakout channels created recently that grew rapidly from scratch.

Discovers new channels that recently solved the YouTube algorithm rather than legacy giants.

Args: niche: Topic or niche keyword (e.g. 'ai automation', 'finance beginners'). max_channel_age_months: Maximum channel age in months (default 24). min_subscribers: Minimum subscribers (default 1000). max_subscribers: Maximum subscribers (default 300000). region_code: ISO country code (default 'US'). max_results: Max results to return (default 10).

find_content_gapsA

Identify high-demand content gaps and low-competition keyword opportunities.

Finds topics where top search results are outdated (2+ years old), signaling easy ranking opportunities for a new channel to displace them with a fresh 2026 update.

Args: niche_or_topic: Topic, query, or question to analyze (e.g. 'how to learn sql for data analysis'). max_results: Number of search results to inspect (default 15). region_code: ISO country code (default 'US').

generate_retention_script_outlineA

Generate a full 8-12 minute retention-engineered YouTube video script outline.

Reverse-engineers competitor transcripts for opening hooks and integrates real viewer pain points from comments to maximize watch time and viewer satisfaction.

Args: video_title_or_topic: The topic or title of the video to outline. competitor_video_id_or_url: Optional competitor video to model hook and structure from. target_audience: Ideal viewer demographic (default 'Beginners'). target_duration_minutes: Target video runtime in minutes (default 10).

discover_niche_sponsorsA

Discover brands actively sponsoring creators in a niche with discount codes and URLs.

Reveals companies with active influencer marketing budgets in your niche so you can pitch them as soon as you reach 1k-5k views per video.

Args: niche_or_query: Niche topic or keyword (e.g. 'productivity apps', 'coding', 'fitness'). sample_videos: Number of top videos to inspect (10 to 30, default 20). region_code: Country code (default 'US').

generate_thumbnail_conceptsA

Generate 3 distinct high-CTR thumbnail visual concepts with AI image prompts.

Deconstructs title-to-thumbnail contrast, visual color theory, facial expressions, and provides ready-to-use prompts for Midjourney, DALL-E, or Imagen.

Args: video_title: The title or topic of the video (e.g. 'How I Built a $10k/mo Micro-SaaS'). target_niche: Optional niche context (e.g. 'coding', 'business', 'productivity'). competitor_video_id_or_url: Optional competitor video to evaluate thumbnail benchmarks.

generate_seo_metadata_packA

Generate a complete YouTube Studio upload package: 3 mobile titles, chapters, description, tags, and pinned comment.

Args: topic: Primary topic or draft title of the video. key_takeaways: Optional list of main points covered in the video. channel_name: Optional creator channel name. affiliate_links: Optional list of affiliate/product URLs.

export_research_reportA

Generate a publication-ready Markdown research report for Notion or Obsidian.

Runs comprehensive market research and formats it into an executive-ready .md document complete with tables, competitor rankings, viral video links, comment insights, and a 5-video roadmap.

Args: niche: Topic or niche (e.g. 'ai automation', 'productivity systems', 'personal finance'). target_audience: Optional target audience description (e.g. 'beginners', 'freelancers'). output_file: Optional path where to save the markdown file (defaults to reports/_research_report.md). region_code: Country market code (default 'US').

find_cross_language_opportunitiesA

Identify proven viral US/English video concepts with low competition in non-English markets.

Analyzes viral performance of English videos and checks competition levels in the target language / region (Spanish, French, German, Portuguese, Italian, Arabic, Japanese), providing translated title frameworks and market arbitrage scores.

Args: topic: Core topic in English (e.g. 'notion for students', 'ai automation', 'intermittent fasting'). target_language: Target language code ('es', 'fr', 'de', 'pt', 'it', 'ar', 'ja'). target_region: Target country code ('ES', 'MX', 'FR', 'DE', 'BR', 'IT', 'JP', 'SA'). max_results: Max opportunities to return (default 5).

simulate_title_ctrA

Grade and simulate the click-through-rate (CTR) potential of candidate video titles.

Evaluates titles against YouTube psychological click triggers: curiosity gaps, loss aversion, specificity/numbers, power words, and mobile length sweet-spots (<50 chars). Designates the highest-CTR winning title and provides 3 optimized variations for each candidate.

Args: titles: List of 1 to 8 candidate video titles to test against each other. target_niche: Optional niche context (e.g. 'coding', 'finance', 'gaming').

analyze_optimal_upload_timeA

Analyze competitor publishing schedules to find the optimal day and hour to upload.

Inspects publishing timestamps of top videos in a niche or channel, builds a day-of-week and hour-of-day distribution, and identifies low-competition "Sweet Spot" windows.

Args: niche_or_channel: Niche topic keyword (e.g. 'coding tutorials', 'finance') or creator handle. sample_size: Number of recent competitor uploads to sample (10 to 50, default 25). timezone_offset_hours: Timezone offset from UTC in hours (e.g. -5 for EST, +1 for CET, default 0).

predict_retention_dropoffsA

Analyze video script or transcript pacing to predict viewer drop-off points and suggest pattern interrupts.

Calculates words-per-minute (WPM) across segments, flags flat/monotonous monologue stretches (>45 seconds without visual change or question), and injects timestamped retention resets.

Args: script_or_transcript: Raw text of the draft video script or spoken transcript. video_id_or_url: Optional YouTube Video ID or URL to fetch and evaluate live transcript. target_duration_minutes: Optional target video runtime in minutes.

analyze_community_postsB

Generate high-engagement Community Tab polls, quizzes, and discussion posts.

Leverages YouTube's Community Tab algorithm, which distributes polls into the home feeds of non-subscribers, creating viral discovery for new channels between video releases.

Args: niche_or_channel: Topic, niche, or creator handle (e.g. 'python programming', 'personal finance'). target_goal: Goal for the community strategy ('growth', 'video_validation', 'audience_loyalty').

analyze_shorts_to_longform_ratioA

Analyze a channel's balance between YouTube Shorts and Long-Form videos.

Calculates publishing ratio, view disparities, conversion efficiency, and provides a customized publishing mix recommendation to avoid Shorts cannibalizing long-form watch time.

Args: channel_id_or_handle: Channel handle (e.g. '@aliabdaal', '@mkbhd') or Channel ID. sample_videos: Number of recent uploads to evaluate (10 to 50, default 20).

classify_traffic_potentialA

Classify whether a video topic will succeed via Evergreen Search or Viral Browse Feeds.

Provides algorithmic traffic predictions, expected RPM / AdSense monetization multipliers, longevity expectations (3+ years vs 14 days), and optimized title variants for both traffic channels.

Args: topic_or_title: Candidate video title, topic, or draft concept. target_niche: Optional niche context (e.g. 'coding', 'personal finance', 'fitness').

generate_monetization_offersA

Architect 3 high-converting day-one monetization offers for channels with under 1,000 subscribers.

Enables creators to generate $500 - $3,000/mo from digital products, lead magnets, and consulting without waiting to reach the YouTube Partner Program AdSense threshold.

Args: niche: Topic or niche (e.g. 'notion productivity', 'python coding', 'budget travel'). target_audience: Target viewer demographic (e.g. 'freelancers', 'students', 'beginners'). main_skill_or_topic: Specific core skill being taught (optional).

design_binge_playlistA

Architect a 4-to-6 video binge-watching loop engineered to trigger YouTube's Session Watch Time multiplier.

Structures interconnected video concepts with seamless cliffhanger bridges and end-screen scripts so viewers watch multiple videos in sequence, signalling algorithmic promotion.

Args: core_topic: Overarching topic or learning journey (e.g. 'Build a SaaS in Python', 'Notion for Beginners'). video_count: Number of videos in the binge playlist series (3 to 6, default 5). target_audience: Optional target audience context.

get_channel_rss_videosA

Fetch the latest video uploads from a YouTube channel using the public Atom RSS feed.

Consumes 0 Google Cloud API quota units and requires NO API key. Ideal for monitoring recent uploads without burning quota.

Args: channel_id: The YouTube Channel ID (e.g., 'UCuAXFkgsw1L7xaCfnd5JJOw') or channel URL. max_results: Maximum recent uploads to return (1 to 15, default 15).

Prompts

Interactive templates invoked by user choice

NameDescription
launch_new_channel_promptGuided prompt for new creators: full niche research and 30-day launch plan.
viral_video_ideas_promptGuided prompt to generate 10 high-CTR video ideas for beginners with proven demand.
competitor_playbook_promptGuided prompt to reverse-engineer any creator's strategy for a new channel to model.

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/mohamdben-yahia/youtube-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server