2

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

Community
  • 1
  • 1
Daniel Burke
  • 21
  • 1
  • 3

2 Answers2

0

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.

Community
  • 1
  • 1
Mr.Rebot
  • 6,703
  • 2
  • 16
  • 91
  • Well I want to get the video ID number and generic "Private video" title of videos that I did **not** own that were set to private in my youtube playlists. These private videos are still in my playlist, they aren't mine, but they are set to private. I wanted to be notified when these videos were no longer public. I tried using the PlaylistItems: list and using the Advanced Google Services to enable Youtube's API 's. But Youtube doesn't provide the generic "private video" title and video ID when fetching playlistitems. I wanted to see if I'm doing something wrong or Youtube has changed. – Daniel Burke Nov 14 '16 at 22:49
  • 1
    I think something changed in the API, I used to be able to identify Private videos and remove them from my playlists. Now the Playlist item is simply not returned, even thought the total count of items is correct : "totalResults": 4, but I only get 3 items in the data structure. – Tym Dec 13 '16 at 19:37
0

This issue has been fixed. You now get the behavior you were used to.

lacton
  • 2,316
  • 2
  • 22
  • 24