YouTube API by APISH avatar

YouTube API by APISH

Pricing

$4.00 / 1,000 credits

Go to Apify Store
YouTube API by APISH

YouTube API by APISH

YouTube data as clean JSON via APISH: YouTube channel, YouTube channel about, YouTube channel live streams and 22 more endpoints. Pay per credit; failed calls are free.

Pricing

$4.00 / 1,000 credits

Rating

0.0

(0)

Developer

APISH

APISH

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

3 days ago

Last modified

Categories

Share

Get public YouTube data as clean, consistent JSON: youTube channel, youTube channel about, youTube channel live streams, youTube channel playlists, youTube channel podcasts, youTube channel community posts and more. 25 endpoints, one response shape, numbers parsed, absolute URLs.

How to use

  1. Pick an Endpoint. Each option shows what it returns and its price in credits.
  2. Enter its Parameters as JSON, for example {"channel":"Google"}. All parameters are listed below.
  3. Run. Each call becomes one row in the dataset. Use Batch to run the same endpoint for many inputs and Pages per input to follow pagination.

Pricing

Pay per event: you pay per APISH credit the call used. The price of each endpoint is in the table below. Calls that fail on our side (server errors, timeouts, blocks) are free.

Endpoints

EndpointReturnsRequired parametersCredits
/youtube/v1/channelYouTube channelchannel1
/youtube/v1/channel/aboutYouTube channel aboutchannel1
/youtube/v1/channel/livesYouTube channel live streamschannel1
/youtube/v1/channel/playlistsYouTube channel playlistschannel1
/youtube/v1/channel/podcastsYouTube channel podcastschannel1
/youtube/v1/channel/postsYouTube channel community postschannel1
/youtube/v1/channel/searchYouTube search within a channelchannel, q1
/youtube/v1/channel/shortsYouTube channel Shortschannel1
/youtube/v1/channel/videosYouTube channel videoschannel1
/youtube/v1/chartsYouTube Charts—1
/youtube/v1/comment/repliesReplies to a YouTube commentcursor1
/youtube/v1/commentsYouTube video commentsvideo_id1
/youtube/v1/hashtagYouTube videos for a hashtaghashtag1
/youtube/v1/playlistYouTube playlisturl1
/youtube/v1/postYouTube community posturl1
/youtube/v1/post/commentsYouTube community post commentsurl1
/youtube/v1/searchYouTube searchq1
/youtube/v1/search/typeaheadYouTube search suggestionsq1
/youtube/v1/shortsOne YouTube shortid1
/youtube/v1/shorts/trendingTrending YouTube Shorts—1
/youtube/v1/transcriptYouTube video transcriptvideo_id1
/youtube/v1/videoOne YouTube videoid1
/youtube/v1/video/chatYouTube live chat replayid1
/youtube/v1/video/relatedYouTube related videosid1
/youtube/v1/video/sponsorsSponsors in a YouTube video (segments, promo codes, links)url1

Output

Each dataset row has endpoint, params, status, credits_used and the endpoint's data. Add "raw": 1 to the parameters to also get the site's original record, or "fields": "a,b.c" to return only the fields you need.

Endpoint details

YouTube channel

Endpoint /youtube/v1/channel · 1 credit per successful call.

Parameters:

  • channel (required): Channel handle, with or without @.

Example parameters: {"channel":"Google"}

YouTube channel about

Endpoint /youtube/v1/channel/about · 1 credit per successful call.

The channel's About panel: description, country, join date, subscriber/view/video totals and every external link (with its real target). Every response includes credits_used: the credits this call cost.

Parameters:

  • channel (required): Handle (@mkbhd), channel id (UC…) or channel URL.

Example parameters: {"channel":"@mkbhd"}

YouTube channel live streams

Endpoint /youtube/v1/channel/lives · 1 credit per successful call.

Parameters:

  • channel (required)
  • sort — one of latest, popular, oldest: latest (default), popular or oldest: the tab's own sort chips; next_cursor keeps the order.
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"channel":"@NASA"}

YouTube channel playlists

Endpoint /youtube/v1/channel/playlists · 1 credit per successful call.

Parameters:

  • channel (required)
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"channel":"@NASA"}

YouTube channel podcasts

Endpoint /youtube/v1/channel/podcasts · 1 credit per successful call.

The channel's Podcasts tab: its podcast playlists (episode count, thumbnail). Empty when the channel has none. Pass next_cursor back as cursor. Every response includes credits_used: the credits this call cost.

Parameters:

  • channel (required): Handle, channel id or channel URL.
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"channel":"@TheDiaryOfACEO"}

YouTube channel community posts

Endpoint /youtube/v1/channel/posts · 1 credit per successful call.

Parameters:

  • channel (required)
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"channel":"@MrBeast"}

YouTube search within a channel

Endpoint /youtube/v1/channel/search · 1 credit per successful call.

The channel's own Search tab: its videos (and playlists) matching the query. Pass next_cursor back as cursor. Every response includes credits_used: the credits this call cost.

Parameters:

  • channel (required): Handle, channel id or channel URL.
  • q (required): Search text.
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"channel":"@mkbhd","q":"iphone"}

YouTube channel Shorts

Endpoint /youtube/v1/channel/shorts · 1 credit per successful call.

Parameters:

  • channel (required)
  • sort — one of latest, popular, oldest: latest (default), popular or oldest: the tab's own sort chips; next_cursor keeps the order.
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"channel":"@MrBeast"}

YouTube channel videos

Endpoint /youtube/v1/channel/videos · 1 credit per successful call.

Pass next_cursor back as cursor for the next videos. next_cursor is null on the last page.

Parameters:

  • channel (required): Channel handle, with or without @.
  • sort — one of latest, popular, oldest: latest (default), popular or oldest: the tab's own sort chips; next_cursor keeps the order.
  • cursor: Cursor from next_cursor on the previous response; next_cursor is null on the last page.

Example parameters: {"channel":"Google"}

YouTube Charts

Endpoint /youtube/v1/charts · 1 credit per successful call.

YouTube's music charts (charts.youtube.com) for a country or worldwide: weekly top songs, artists and music videos (100 each), weekly top songs on Shorts (50) and daily trending music videos (30), with rank, previous rank, periods on chart, views and their change, artists, release date, songwriters and producers. available_charts lists the charts and date ranges the country has. One page per chart. Every response includes credits_used: the credits this call cost.

Parameters:

  • chart — one of songs, artists, videos, shorts_songs, trending: songs (default), artists, videos, shorts_songs or trending.
  • country: global (default) or a two-letter country code (us, in, gb, br, ...).

Replies to a YouTube comment

Endpoint /youtube/v1/comment/replies · 1 credit per successful call.

Parameters:

  • cursor (required): replies_cursor of a comment from /youtube/v1/comments.

Example parameters: {"cursor":"Eg0SC2RRdzR3OVdnWGNRGAYygwEaUBIaVWd6S1lrc3FlUTVnQTN0MGcwRjRBYUFCQWciAggAKhhVQ3VBWEZrZ3N3MUw3eGFDZm5kNUpKT3cyC2RRdzR3OVdnWGNRQAFICoIBAggBQi9jb21tZW50LXJlcGxpZXMtaXRlbS1VZ3pLWWtzcWVRNWdBM3QwZzBGNEFhQUJBZw%3D%3D"}

YouTube video comments

Endpoint /youtube/v1/comments · 1 credit per successful call.

Pass next_cursor back as cursor for the next comments. next_cursor is null on the last page.

Parameters:

  • video_id (required)
  • sort — one of top, newest: top (default) or newest, as in the comments header; next_cursor keeps the order.
  • cursor: Cursor from next_cursor on the previous response; next_cursor is null on the last page.

Example parameters: {"video_id":"dQw4w9WgXcQ"}

YouTube videos for a hashtag

Endpoint /youtube/v1/hashtag · 1 credit per successful call.

Parameters:

  • hashtag (required)
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"hashtag":"cooking"}

YouTube playlist

Endpoint /youtube/v1/playlist · 1 credit per successful call.

Parameters:

  • url (required)
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"url":"https://www.youtube.com/playlist?list=PLBsP89CPrMeMV1oP42Zn2DrWpnFoSaufA"}

YouTube community post

Endpoint /youtube/v1/post · 1 credit per successful call.

Parameters:

  • url (required)

Example parameters: {"url":"https://www.youtube.com/post/UgkxHIfkQ3K2my65-kPq4VkRv9KrBRyN7alx"}

YouTube community post comments

Endpoint /youtube/v1/post/comments · 1 credit per successful call.

Comments on a community post. Each comment carries replies_cursor for /youtube/v1/comment/replies. Pass next_cursor back as cursor. Every response includes credits_used: the credits this call cost.

Parameters:

  • url (required): Post URL (https://www.youtube.com/post/
  • sort — one of top, newest: top (default) or newest.
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"url":"https://www.youtube.com/post/UgkxHIfkQ3K2my65-kPq4VkRv9KrBRyN7alx"}

Endpoint /youtube/v1/search · 1 credit per successful call.

Pass next_cursor back as cursor for the next results. next_cursor is null on the last page.

Parameters:

  • q (required)
  • sort — one of relevance, rating, date, views: relevance (default), rating, date or views.
  • type — one of video, channel, playlist, movie: video, channel, playlist or movie. Channels come back under channels, playlists under playlists.
  • duration — one of short, medium, long: short (under 4 min), medium (4-20 min) or long (over 20 min).
  • upload_date — one of hour, today, week, month, year: hour, today, week, month or year.
  • features: Comma-separated: hd, subtitles, creative_commons, 3d, live, purchased, 4k, 360, location, hdr, vr180.
  • hl: Interface language of the results (ISO 639-1), default en.
  • gl: Country of the results (ISO 3166-1 alpha-2), default US.
  • cursor: Cursor from next_cursor on the previous response; next_cursor is null on the last page.

Example parameters: {"q":"lofi"}

YouTube search suggestions

Endpoint /youtube/v1/search/typeahead · 1 credit per successful call.

Parameters:

  • q (required)

Example parameters: {"q":"how to"}

One YouTube short

Endpoint /youtube/v1/shorts · 1 credit per successful call.

Parameters:

  • id (required)

Example parameters: {"id":"dQw4w9WgXcQ"}

Endpoint /youtube/v1/shorts/trending · 1 credit per successful call.

Parameters:

  • period: today, week or month.

YouTube video transcript

Endpoint /youtube/v1/transcript · 1 credit per successful call.

Parameters:

  • video_id (required)
  • url: Video URL (instead of video_id).

Example parameters: {"video_id":"aircAruvnKk"}

One YouTube video

Endpoint /youtube/v1/video · 1 credit per successful call.

Everything the watch page has for a video: details, formats, captions, chapters, heatmap ("Most replayed"), related videos and more. Every response includes credits_used: the credits this call cost.

Parameters:

  • id (required)

Example parameters: {"id":"dQw4w9WgXcQ"}

YouTube live chat replay

Endpoint /youtube/v1/video/chat · 1 credit per successful call.

The chat replay of a past live stream (when the stream kept its chat): messages, Super Chats and memberships with author, badges, amount and the video offset. Pass next_cursor back as cursor to read on. Every response includes credits_used: the credits this call cost.

Parameters:

  • id (required): Video id or URL of a past stream.
  • mode — one of top, all: top (default, Top chat replay) or all (Live chat replay).
  • start_s: Start reading at this many seconds into the stream (first page only).
  • cursor: Value of next_cursor from the previous page.

Example parameters: {"id":"rbbkNlvx7PM"}

Endpoint /youtube/v1/video/related · 1 credit per successful call.

The watch page's "Up next" list for a video, without the player data (cheaper than /youtube/v1/video). Every response includes credits_used: the credits this call cost.

Parameters:

  • id (required): Video id or URL.
  • cursor: Value of next_cursor from the previous page (YouTube returns one page to logged-out visitors for most videos).

Example parameters: {"id":"dQw4w9WgXcQ"}

Endpoint /youtube/v1/video/sponsors · 1 credit per successful call.

Parameters:

  • url (required)

Example parameters: {"url":"https://www.youtube.com/watch?v=dQw4w9WgXcQ"}

Support

Questions, bugs or a missing field? Open an issue in this Actor's Issues tab and we will reply there.

Public data only: nothing behind a login. You are responsible for how you use the data you collect.