I have this as a request for youtube api in displaying videos of a particular video playlist https://www.googleapis.com/youtube/v3/playlistItems?part=snippet&playlistId='+playlist_id+'&key={My Key}
The Problem
How will I able to have a request that will search a video in that particular video playlist?
you can add the video id and have it return just that video.
videoId string
The videoId parameter specifies that the request should
return only the playlist items that contain the specified video.
If the question is how do I return only the "dog" videos in the playlist, the answer is you cant. There is no free text searching in playlistitems.list
Related
I am using google youtube API v3 to get playlist details by playlist id but in result it is showing second video thumbnail.
Do you have any idea How can i get first video thumbnail?
https://developers.google.com/youtube/v3/docs/playlists/list
Is it possible to get the ID of the last uploaded video to the specific YouTube channel, based on channel name, eventually channel ID?
I need get a thumbnail from last video:
http://img.youtube.com/vi/<VIDEO-ID>/maxresdefault.jpg
In order to get this video id you can use the YouTube Data API
You can make a curl request to: https://www.googleapis.com/youtube/v3/search?key={your_key_here}&channelId={channel_id_here}&part=snippet,id&order=date&maxResults=1
This would return a JSON with a video id for the latest youtube video.
youtube api responses wrong video items of this kind of playlist:
https://www.youtube.com/playlist?list=OLAK5uy_lSUrVP8K-w63I5BQyJKXdoxZNkMvU1T6w
You guys can see the actual api response by this link
This is a video returned from the api:
https://www.youtube.com/watch?v=Vdq1DWaxrJ0
But it doesn't exists in the playlist above, moreover I can't play this video because The uploader has not made this video available in your country. It looks like a "special video" of YouTube Music, lets see it thumbnail: https://i.ytimg.com/vi/Fc3Mj63xmPo/maxresdefault.jpg
Anyone know what happened?
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.
I am fetching all the videos from the youtube playlist. I am following the procedure given in this answer
Retrieve all videos from youtube playlist using youtube v3 API
I am able to fetched 50 videos of the playlist and to get the remaning result I am passing the url like that
#"https://www.googleapis.com/youtube/v3/playlistItems?pageToken=%# &part=snippet&playlistId=PL_aEw_4hMkBfAWoYqB6I0G1Oe0qtqcqwF&key={MY_API_KEY}",[jsonDict valueForKey:#"nextPageToken"]];
But I am getting url nil and doesn't getting any result.
How can I fetch other videos from youtube playlist??
You are doing right just replace this url with this
#"https://www.googleapis.com/youtube/v3/playlistItems?part=snippet&pageToken=%#&playlistId=PL_aEw_4hMkBfAWoYqB6I0G1Oe0qtqcqwF&key={your_api_key}",[jsonDict valueForKey:#"nextPageToken"]