YouTube API : Getting list of channels of a specific genre - youtube

I want to get list of channels of a specific genre in my App using YouTube API.
For Example -
I want to get list of all comedy channels on YouTube in my App.
Is this possible , if yes than How ?

YouTube's V3 API doesn't have a category for each channel.
Take a look at this similar question: How to get the Channel Type or Category of each YouTube channel using YouTube API?
YouTube documentation for this: https://developers.google.com/youtube/v3/docs/channels
The YouTube API does however show if videos and by extension channels make videos for kids.

Related

How to Retrieve the Video ID from private videos within a public Playlist- YouTube API v3?

I need some help getting the video ID number and the video title ( the title would be "Private video") for all private videos within a public playlist. Specifically I'd need help editing my script below. This script used to be able to do that, but I fear something has changed with Youtube's API. I want to know if there is any way to get this information and fix my script.
My script is located here
Just a month ago my script (see above) was able to retrieve video ID numbers and video names of private videos when fetching playlistItems from a playlistid (of course the video titles were renamed "Private video" - but that is the info I wanted). Unfortunately now when I fetch the same playlistid from youtube it hides all this info. It acts as if there are no videos in the playlist when a playlist contains private videos. Here is a question asked last year, it shows you can pull the video ID numbers and names from a playlist that contained private videos. Retrieve Video IDs contained in a Playlist - YouTube API v3
Here is an example of a playlist I would want to fetch the video ID and video name from.
https://www.youtube.com/playlist?list=PLAg_-NsALZoOLfXbX7eGIzFsbG21XAvct
I haven't tried it but you can try PlaylistItems: list and Advanced Google Services
Returns a collection of playlist items that match the API request parameters. You can retrieve all of the playlist items in a specified playlist or retrieve one or more playlist items by their unique IDs.
AFAIK if you own the private/unlisted videos, you can get the videos using Youtube API v3. You can read these related SO questions - Using the YouTube API v3 to list all private videos, Google Youtube Data API: Private videos with API key and Google YouTube API (v3): how to access my unlisted/private videos from my server? that all discuss retrieving the ID as the owner of the videos.
This issue has been fixed. You now get the behavior you were used to.

Youtube data apis 3.0: how to get channel video urls using video.list api?

I am using youtube data apis 3.0. I want to get the NDTV channel videos to publish in our site.
I can get the list of videos description and some other basic info, but I want information like file details, ratings, liveStreamingDetails, player, processingDetails, recordingDetails, statistics, status, suggestions, topicDetails etc...
can any one please help me?
This is the way to grab the last 50 (maximum allowed) videos of a user with Youtube with Api 3.0
//search channels of user
https://www.googleapis.com/youtube/v3/channels?part=contentDetails&forUsername={USERNAME}&key={KEY}
//search playlist items of upload channel
https://www.googleapis.com/youtube/v3/playlistItems?part=snippet&maxResults=50&playlistId={PLAYLIST}&key={KEY}
//search videos of the playlist items of the upload channel
https://www.googleapis.com/youtube/v3/videos?part=id,snippet,contentDetails,status&id=BBfPP0rTjxo,o04cSB5afGc&maxResults=50&key={KEY}

Filter videos for children youtube API

I am developing an iOS video player app for children. Is there a way to filter youtube videos for children by using youtube api.
May be i'm wrong, but I think there there is no specific filter youtube videos,
but you can set safeSearch=strict or
search in education category

Adding all videos from a YouTube channel to a website

I'm trying to feed videos from a YouTube channel to a website. I've been able to add the videos one by one but I would like to add the whole YouTube channel very interactively on the website. Any idea?
Using Data API v3, you can get a list of all playlists associated with your channel.
'https://developers.google.com/youtube/v3/docs/channels#properties' ->
'contentDetails.relatedPlaylists'
Iterating through these playlists, you can get video ids and feed them.
'https://developers.google.com/youtube/v3/docs/playlistItems#resource' ->
'contentDetails.videoId'
Or you can put the whole playlist as a player by,
going to playlists ->
'player.embedHtml'

How to get share count of a youtube video using youtube api?

I'm using youtube to retrive some data on a youtube channel (title, id, keywords, lenght, publication-date, ...)
I want to know how to get the share count of each video in this channel.
I want to build a "top 10 most shared video" of a specific channel.
Have a look at the YouTube Analytics API:
https://developers.google.com/youtube/analytics/
There is a metric for retrieving the share count (shares). Use dimensions (dimensions=video&metric=shares). Alternatively, use filters if you want to retrieve the share count for a specific video: video==Zhawgd0REhA. For more info, see:
https://developers.google.com/youtube/analytics/v1/available_reports

Resources