Catalog / YouTube

YouTube API

youtube.com

Search public YouTube videos and retrieve live video metadata, including titles, channels, view counts, and descriptions. No YouTube login is needed.

  • Social & video
  • youtube
  • video
  • channel
  • search
  • metadata
3 endpointsDocs updated

Endpoint health

Loading verification…

Connect your agent

Connect through MCP so your agent can find this API, read its docs, and call its endpoints.

Setup guide

Add the server from your terminal.

Claude Code · terminal
claude mcp add --transport http agent-data https://agent-data.motie.dev/mcp

In Claude Code, run /mcp, select agent-data, then Authenticate. Sign in to your agent-data account in the browser.

Then ask your agent to use the YouTube API for your task.

Call it over HTTP

Get an API key

Sign up free, generate an API key, and set it as AGENT_DATA_API_KEY in your environment. Your first 100 calls each month are free.

Search YouTube videos

Terms to search for on YouTube.

Optional parameters 1

Opaque cursor returned by a previous search response; reuse it with the same query.

View call pricing
cURL · Search videos
curl --request GET --get 'https://api.agent-data.dev/youtube-com/v1/search-videos' \
  --header "Authorization: Bearer $AGENT_DATA_API_KEY" \
  --data-urlencode 'query=python programming'

Endpoints

Inputs and response fields for every endpoint in this API.

GETSearch videos/v1/search-videos

Search YouTube videos

Input

queryRequiredQuery · string

Terms to search for on YouTube.

Example: python programming

cursorOptionalQuery · string | null

Opaque cursor returned by a previous search response; reuse it with the same query.

Response

itemsobject[]
items[].titlestring
items[].durationstring | null
items[].video_idstring
items[].video_urlstring
items[].channel_idstring | null
items[].channel_namestring | null
items[].thumbnail_urlstring | null
items[].duration_secondsinteger | null
items[].publication_informationstring | null
next_cursorstring | null

For the next page, pass next_cursor from the response as cursor. Leave it empty on the first call.

GETGet video details/v1/video-details

Get public YouTube video metadata

Input

videoRequiredQuery · string

An 11-character YouTube video ID or a youtube.com/watch?v=... URL.

Example: dQw4w9WgXcQ

Response

titlestring
durationstring | null
video_idstring
video_urlstring
channel_idstring | null
like_countinteger | null
thumbnailsobject[]
thumbnails[].urlstring
thumbnails[].width?integer | null
thumbnails[].height?integer | null
view_countinteger | null
descriptionstring
channel_namestring | null
published_atstring | null
duration_secondsinteger | null

Fields marked ? are optional.

GETChannel profile/v1/channel-profile

Get a public YouTube channel profile

Input

channelRequiredQuery · string

A 24-character YouTube channel ID or a public YouTube channel URL.

Example: UCuAXFkgsw1L7xaCfnd5JJOw

Response

namestring
channel_idstring
descriptionstring
canonical_urlstring
subscriber_countstring | null

Don’t see the endpoint you need?

Ask agent-data to add an endpoint or return more fields. Extensions are free and keep existing endpoints working.