Skip to main content
Glama

youtube-transcript-mcp

MCP-сервер, который даёт программному агенту возможность читать и искать по транскриптам видео YouTube. Без API-ключа, без учётной записи Google, без регистрации. Он получает субтитры через публичные конечные точки YouTube и добавляет одну небольшую вещь, которой нет в простом дампе транскрипта: сводки по главам.

Это начиналось как небольшой инструмент для личного использования. Я постоянно сталкивался с разговорами, содержащими ссылку на YouTube, и мне нужно было знать, что на самом деле говорится в видео, а повторная вставка транскриптов отнимала время. Он превратился в переиспользуемый сервер, чтобы всё, что работает на Model Context Protocol, могло просто спросить.

Что он делает

  • get_transcript(video_url_or_id, languages=["en"], include_timestamps=False) получает полный транскрипт в виде обычного текста. Он принимает полный URL YouTube (watch?v=, youtu.be, /embed/, /shorts/, /live/) или просто 11-символьный идентификатор видео.

  • get_video_metadata(video_url_or_id) возвращает название, имя канала, URL канала и миниатюру через oEmbed-конечную точку YouTube без аутентификации. Он намеренно не возвращает дату публикации или полное описание, потому что для них нужен официальный ключ Data API, а вся суть здесь в том, что он вам не нужен.

  • search_transcript(video_url_or_id, query, languages=["en"]) находит сегменты, соответствующие ключевому слову или фразе, без учёта регистра, каждый с временной меткой [mm:ss], чтобы модель могла указать, где в видео было сказано что-то.

  • summarize_chapters(video_url_or_id, gap_seconds=4.0, min_chunk_seconds=45.0, languages=["en"]) разбивает транскрипт на приблизительные временные блоки по естественным паузам и возвращает их, чтобы агент мог резюмировать раздел за разделом, а не глотать один гигантский кусок. Это эвристика, а не настоящие данные глав YouTube.

Все инструменты возвращают обычную строку, включая ошибки (например, "Error: captions are disabled for this video"). Никакие исключения не всплывают к вызывающему агенту, и никакие трассировки стека не утекают.

Related MCP server: YouTube for AI Agents

Что он намеренно не делает

  • Он не работает с видео, где субтитры отключены, с приватными или недоступными видео, а также с прямыми трансляциями без субтитров. Он сообщает об этом, а не угадывает.

  • Он не зависит от YouTube Data API. Вы не можете получить даты публикации или полные описания без него, и это сделано намеренно.

  • Он не кэширует. Два вызова одного и того же видео каждый раз загружают его заново. Для реального использования инструмента это нормально. Добавьте кэширование, если когда-нибудь понадобится при больших объёмах.

Установка

Требуется Python 3.11+ и uv.

uv sync

Запустите его отдельно, чтобы убедиться, что он запускается:

uv run server.py

Он ожидает ввода MCP stdio, поэтому будет казаться, что он ничего не делает, пока не подключится клиент. Это нормально. Ctrl+C для выхода.

Регистрация в MCP-клиенте

Добавьте его в настройки MCP вашего клиента. Сервер вызывается через stdio, поэтому конфигурация представляет собой командную строку. В качестве примера используем Claude CLI:

claude mcp add youtube-transcript -- uv --directory /absolute/path/to/youtube-transcript-mcp run server.py

Или в JSON-конфигурации:

{
  "mcpServers": {
    "youtube-transcript": {
      "command": "uv",
      "args": ["--directory", "/absolute/path/to/youtube-transcript-mcp", "run", "server.py"]
    }
  }
}

Заметки, добытые с трудом

  • Работают только видео с субтитрами (автоматическими или ручными). Видео без субтитров возвращает понятную ошибку, и это осознанный выбор: пустой результат выглядит как тихий сбой, а ошибка называет причину.

  • Список языков важен. languages=["en"] получает английскую дорожку, если она существует. Если канал загружает видео только на другом языке, передайте этот код.

  • Закрепите mcp>=1.28.1, но оставайтесь ниже 2.0. В mcp 2.x переименован mcp.server.fastmcp, и импорт молча ломается при запуске сервера. Вам нужна версия, которая действительно загружается.

Лицензия

MIT. См. LICENSE.

Available Tools

4 tools
get_transcriptA

Fetch the full transcript of a YouTube video as plain text.

Args:
    video_url_or_id: Full YouTube URL (watch/youtu.be/embed/shorts) or bare 11-char video ID.
    languages: Preferred language codes in priority order, e.g. ["en", "en-GB"]. Defaults to ["en"].
    include_timestamps: If true, prefix each line with a [mm:ss] timestamp.
ParametersJSON Schema
NameRequiredDescriptionDefault
languagesNo
video_url_or_idYes
include_timestampsNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the burden of behavior and does a good job: it explains accepted URL formats, the bare ID alternative, language priority ordering, the default language list, and timestamp formatting. It does not mention edge cases like missing captions or rate limits, but the disclosed behavior covers the core interaction well.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and well-structured: a one-line purpose, followed by a concise Args block. Every sentence earns its place, and parameter docs are front-loaded with the needed specifics.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a three-parameter tool with an output schema, the description provides enough to invoke the tool correctly: required argument, optional language behavior, and timestamp control. It could be strengthened with guidance about when to use sibling tools or what happens when no transcript is available, but it is largely complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, and it does thoroughly. Each parameter is explained with concrete examples, accepted formats, defaults, and behavioral effects, adding substantial meaning beyond the bare schema properties.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The first sentence clearly states the action ('Fetch the full transcript'), the resource ('YouTube video'), and the output form ('as plain text'). The word 'full' differentiates it from sibling tools like search_transcript, which implies partial or query-based retrieval.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by the purpose: use this tool when you need the complete transcript of a YouTube video. However, there is no explicit guidance about when to prefer search_transcript, get_video_metadata, or summarize_chapters instead, nor exclusions such as 'use search_transcript for snippets'.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_video_metadataA

Fetch title, channel name, and thumbnail for a YouTube video via the no-auth oEmbed endpoint.

Note: oEmbed does not expose upload date or full description (those require the official
Data API + an API key). This returns what's available without one.

Args:
    video_url_or_id: Full YouTube URL or bare 11-char video ID.
ParametersJSON Schema
NameRequiredDescriptionDefault
video_url_or_idYes

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations available, the description carries the behavioral disclosure burden. It credibly explains that the tool uses a no-auth endpoint, returns only a limited set of metadata, and does not expose upload date or full description. It could also mention error behavior or invalid inputs, but the core behavioral limitations are transparently disclosed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded with the main purpose. The limitation note is valuable context, and the Args section is minimal and directly useful. Every sentence contributes to correct invocation.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a single-parameter metadata retrieval tool with a provided output schema, the description covers purpose, input format, expected returned fields, and key limitations. Nothing essential for selecting or invoking the tool is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema provides only a bare string type with 0% description coverage, but the description fully compensates by defining accepted values: 'Full YouTube URL or bare 11-char video ID.' This gives the agent exactly what it needs to construct a valid argument.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb ('Fetch') and names the exact resources returned ('title, channel name, and thumbnail'), clearly distinguishing this from the transcript-focused sibling tools. It also names the mechanism ('no-auth oEmbed endpoint'), leaving no ambiguity about what the tool does.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description clearly implies when to use this tool (when basic YouTube metadata is needed without authentication) and explicitly notes when it is insufficient (when upload date or full description is required, which 'require the official Data API + an API key'). It does not explicitly reference sibling tools, but the field-level exclusions provide solid guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

search_transcriptA

Search a video's transcript for a keyword/phrase and return matching segments with timestamps.

Args:
    video_url_or_id: Full YouTube URL or bare 11-char video ID.
    query: Keyword or phrase to search for (case-insensitive substring match).
    languages: Preferred language codes in priority order. Defaults to ["en"].
ParametersJSON Schema
NameRequiredDescriptionDefault
queryYes
languagesNo
video_url_or_idYes

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the burden of behavioral disclosure. It does disclose that query matching is case-insensitive and substring-based, and that languages default to ['en']. However, it does not mention what happens when no transcript is available, whether network fetching is involved, or how missing language captions are handled.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description opens with a precise one-sentence purpose and then uses a clean bulleted Args list. There is no redundant or filler text; every sentence earns its place and the most important information is front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity, the description covers purpose, return type (matching segments with timestamps), and all parameters. An output schema exists to cover return-value details, but the description does not address edge cases or when to choose this tool over siblings, so it is not fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description fully compensates by explaining all three parameters: video_url_or_id accepts a full URL or bare 11-char ID, query is a case-insensitive substring match, and languages are priority-ordered with a default. This adds significant meaning beyond the bare schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action: search a video's transcript for a keyword/phrase and return matching segments with timestamps. It differentiates itself from sibling tools like get_transcript and get_video_metadata by focusing on search-within-transcript rather than retrieval of the full transcript or metadata.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The purpose implies when to use it (when you need to find specific content in a transcript rather than reading the whole transcript), but it does not explicitly state when to prefer alternatives. No exclusions or alternative routing are provided, so the usage context is only implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

summarize_chaptersA

Break a transcript into rough time-blocked chunks at natural pauses, for easier per-section summarizing.

This is a heuristic, not real chapter data: it splits wherever the gap between two consecutive
caption snippets exceeds `gap_seconds`, then merges any resulting chunk shorter than
`min_chunk_seconds` into its neighbor so chunks stay summarizable.

Args:
    video_url_or_id: Full YouTube URL or bare 11-char video ID.
    gap_seconds: Silence gap (seconds) between captions that triggers a new chunk boundary.
    min_chunk_seconds: Minimum chunk duration; shorter chunks get merged forward.
    languages: Preferred language codes in priority order. Defaults to ["en"].
ParametersJSON Schema
NameRequiredDescriptionDefault
languagesNo
gap_secondsNo
video_url_or_idYes
min_chunk_secondsNo

Output Schema

ParametersJSON Schema
NameRequiredDescription
resultYes

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden and does so admirably. It explicitly discloses that this is 'a heuristic, not real chapter data' and explains the exact split/merge algorithm involving gap_seconds and min_chunk_seconds, so the agent knows what behavior to expect.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The definition is front-loaded with a one-sentence summary, followed by a concise explanation of the heuristic behavior and a clean Args section. Every sentence carries necessary information, and there is no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool has an output schema, so return values need not be repeated. The description covers the algorithm, parameters, defaults, and limitations, which is everything an agent needs to call it correctly. The only minor nuance is languages defaulting to ['en'] in the prose while the schema shows null, but the behavior is still clear.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description alone documents semantics. It gives meaningful explanations for all four parameters, including units ('seconds'), behavior ('triggers a new chunk boundary', 'merged forward'), and accepted values for video_url_or_id. This fully compensates for the schema's lack of descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Break a transcript into rough time-blocked chunks at natural pauses', which clearly defines the tool's output and purpose. It further distinguishes itself from real chapter data and from the sibling retrieval/search tools by stating it is a heuristic chunking operation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'for easier per-section summarizing' gives a clear context and intended use. It does not explicitly name alternatives (get_transcript, search_transcript) or state when not to use it, so it stops short of a 5, but it is not ambiguous.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 4 tool updatesv0.1.0
    • First observedget_transcript
    • First observedget_video_metadata
    • First observedsearch_transcript
    • First observedsummarize_chapters

TDQS

A4.4/5.0
Disambiguation5/5

Each tool targets a distinct operation: fetching raw transcript text, fetching metadata, searching within a transcript, and chunking into chapters. Even though three tools operate on transcripts, their purposes are clearly separated and descriptions make the boundaries obvious.

Naming Consistency5/5

All tool names follow a consistent verb_noun snake_case pattern: get_transcript, get_video_metadata, search_transcript, summarize_chapters. The verbs clearly indicate the action, and the nouns indicate the resource or output.

Tool Count5/5

With 4 tools, the server is well-scoped for a focused YouTube transcript utility. Each tool covers a meaningful, non-redundant capability without unnecessary bloat.

Completeness4/5

The set covers the core transcript workflows: fetching, searching, chunking, and basic metadata retrieval. A minor gap is the lack of a tool to list available transcript languages or caption tracks, which could help when the default language is unavailable.

Maintenance

ActivityMaintained
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

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/luigimasango-dev/youtube-transcript-mcp'

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