Skip to main content
Glama

YouTube

youtube
Read-only

Read public YouTube data with Desearch. Set action and that action's arguments. search (query; optional type, upload_date, sort_by, duration, cursor): videos, Shorts, live streams, channels, and playlists that match a keyword; each result has a type. video (id): one video or Short by ID or URL, with its channel, counts, chapters, and caption languages. transcript (video_id; optional language): its captions as plain text and timestamped segments; a video without captions returns 404. comments (video_id; optional order, cursor): its top-level comments. channel (handle): one channel by handle or channel ID. channel_videos (handle; optional sort, cursor): the channel's videos. A video id from search or channel_videos can be passed to video, transcript, or comments. video, transcript, and channel return the item itself. List actions return { results, next_cursor, next }. For the next page, call again with the same action and target and cursor set to next_cursor, unchanged; next_cursor is null on the last page. A cursor lasts 24 hours.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "action": "<action>"
    },
    "name": "youtube"
  }
}

Input Schema

NameRequiredDescriptionDefault
idNovideo: YouTube video or Short ID, or its full URL, example: 'dQw4w9WgXcQ'.
sortNochannel_videos: video order (API default latest).
typeNosearch: only this kind of result. Omit for mixed results.
orderNocomments: comment order.
queryNosearch: keyword or phrase, example: 'bittensor'. Use intitle:"..." for stricter title matching.
actionYesWhat to read: 'search', 'video', 'transcript', 'comments', 'channel', or 'channel_videos'.
cursorNonext_cursor from the previous page of the same action and target, sent back unchanged. Omit it for the first page.
handleNochannel, channel_videos: channel handle (with or without @) or channel ID (UC...), example: '@MrBeast'.
sort_byNosearch: result order.
durationNosearch: video length. Applies to videos, not Shorts.
languageNotranscript: caption language code, example: 'en' or 'es'. Omit for YouTube's default track.
video_idNotranscript, comments: YouTube video or Short ID, or its full URL.
upload_dateNosearch: only videos uploaded in this window.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior5/5

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

Beyond the annotations (readOnly, openWorld, not destructive), the description discloses crucial behavioral details: return shapes for list vs item actions, pagination mechanics ('call again with the same action and target and cursor set to next_cursor, unchanged'), cursor lifetime ('lasts 24 hours'), and an error case ('a video without captions returns 404'). This is rich context for an agent.

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 front-loaded with a clear one-sentence purpose followed by compact, action-specific details. Every sentence contributes necessary information about capabilities, returns, or pagination, with zero waste for a tool handling 6 actions and 13 parameters.

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?

Given the complexity (6 actions, 13 parameters, no output schema), the description covers what each action does, what it returns, how to paginate, and how to handle an error case. Annotations already cover the read-only/public safety profile, and no additional context is needed for correct invocation.

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

Parameters3/5

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

Schema description coverage is 100%, so each parameter is already documented in the schema. The description mostly reorganizes this information by action, adding only a minor cross-action workflow hint (using a video id from search in video/transcript/comments). It does not add new syntax or constraints beyond what the schema provides.

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

Purpose4/5

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

The description clearly states it reads public YouTube data and enumerates all actions, making the resource and scope unambiguous. It does not explicitly differentiate from sibling social-media tools, but the YouTube-specific purpose is evident from the action list.

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 description provides implied usage by defining each action's arguments (e.g., 'search (query; ...)' or 'video (id)') and mentions cross-action workflow ('A video id from search ... can be passed to video, transcript, or comments'). However, it offers no explicit guidance on when to choose this tool over siblings like tiktok or instagram, nor does it state any exclusions.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.