Tools

YouTube tools

Channels, videos, comments and transcripts.

Public YouTube data. Each call costs what the data provider charges for it, and the cost line under each tool below gives the number. A question YouTube cannot answer has no tool, rather than a tool that returns nothing.

ToolWhat it doesCost
youtube_get_channelGet a YouTube channelFrom 1 credit
youtube_get_videosGet a channel's videosFrom 1 credit
youtube_get_videoGet a YouTube videoFrom 1 credit
youtube_get_commentsGet a video's commentsFrom 1 credit
youtube_search_videosSearch YouTube videosFrom 1 credit
youtube_get_transcriptGet a video's transcriptFrom 1 credit

#Get a YouTube channel

youtube_get_channel

One YouTube channel: subscribers, total views and when it joined.

Use when: sizing a channel before a sponsorship, checking a handle, reading a channel description.

Not for: its videos, use youtube_get_videos. Videos by topic, use youtube_search_videos.

Returns: Record. platform, kind, id, handle, name, url, bio, verified, followers, following, posts_count, likes, views, location, website, employees, industry, created_at. A field the platform does not publish is null. kind is channel, followers is the subscriber count.

Cost: 1 credit. Cached 24 hours.

ParameterDefault and notes
handleRequired, with or without the @

Also takes provider, max_credits, dry_run: see common parameters.

JSON
{
  "handle": "@ThePatMcAfeeShow"
}

#Get a channel's videos

youtube_get_videos

The videos on one YouTube channel, newest or most viewed first.

Use when: "what does this channel publish", judging cadence and view counts before a sponsorship.

Not for: one video in full, use youtube_get_video. What is said in it, use youtube_get_transcript.

Returns: List, one page per call. rows[]: platform, id, url, author, author_name, created_at, text (cut at 2000 characters), likes, comments, shares, views, media, duration_s, is_ad. A number the platform does not publish is null. A listing carries views and length; likes and comments come with youtube_get_video.

Cost: 1 credit per page. Cached 6 hours.

ParameterDefault and notes
handleRequired
sort"latest" | "popular", default latest

Also takes cursor, provider, max_credits, dry_run: see common parameters.

JSON
{
  "handle": "@ThePatMcAfeeShow",
  "sort": "popular"
}

#Get a YouTube video

youtube_get_video

One YouTube video with its views, likes, comments and length.

Use when: a row is worth the detail, or you have a URL and nothing else.

Not for: what is said in it, use youtube_get_transcript. The comments, use youtube_get_comments.

Returns: Record. rows[]: platform, id, url, author, author_name, created_at, text (cut at 2000 characters), likes, comments, shares, views, media, duration_s, is_ad. A number the platform does not publish is null.

Cost: 1 credit. Cached 6 hours.

ParameterDefault and notes
urlRequired

Also takes provider, max_credits, dry_run: see common parameters.

JSON
{
  "url": "https://www.youtube.com/watch?v=5EWaxmWgQMI"
}

#Get a video's comments

youtube_get_comments

The comments on one YouTube video, most liked first.

Use when: reading what an audience said, finding the objections under a review or a tutorial.

Not for: the video itself, use youtube_get_video. What is said in it, use youtube_get_transcript.

Returns: List, one page per call. rows[]: platform, id, post_id, author, created_at, text (cut at 2000 characters), likes, replies, depth. depth is the reply level. meta.cursor pages the next set. created_at is approximate: the platform shows an age such as "3 weeks ago", so it is exact only to that unit.

Cost: 1 credit per page. Cached 6 hours.

ParameterDefault and notes
urlRequired

Also takes cursor, provider, max_credits, dry_run: see common parameters.

JSON
{
  "url": "https://www.youtube.com/watch?v=5EWaxmWgQMI"
}

#Search YouTube videos

youtube_search_videos

YouTube videos matching a keyword, ranked by YouTube's own search.

Use when: "what videos cover X", finding review and tutorial coverage of a product or a competitor.

Not for: one channel's own videos, use youtube_get_videos. Text pages about X, use seo_get_serp.

Returns: List, one page per call, ranked. rows[]: platform, id, url, author, author_name, created_at, text (cut at 2000 characters), likes, comments, shares, views, media, duration_s, is_ad. A number the platform does not publish is null. meta.cursor pages the next set. created_at is approximate: the platform shows an age such as "3 weeks ago", so it is exact only to that unit.

Cost: 1 credit per page. Cached 6 hours.

ParameterDefault and notes
queryRequired
since"day" | "week" | "month" | "year" | "all", default month
sort"relevance" | "latest" | "popular", default relevance

Also takes cursor, provider, max_credits, dry_run: see common parameters.

JSON
{
  "query": "best crm for agencies",
  "since": "year"
}

#Get a video's transcript

youtube_get_transcript

The transcript of one YouTube video, as text.

Use when: reading a video instead of watching it, pulling claims, chapters or quotes out of long content.

Not for: the video's numbers, use youtube_get_video. The comments, use youtube_get_comments.

Returns: Record. platform, url, language, text (the full transcript, uncut). NoData when the video has no captions.

Cost: 1 credit. Cached 30 days.

ParameterDefault and notes
urlRequired
languageOptional, for a video with several

Also takes provider, max_credits, dry_run: see common parameters.

JSON
{
  "url": "https://www.youtube.com/watch?v=5EWaxmWgQMI"
}