1

I am trying to query youtube for all uploads relating to a channel, but for official artist channels such as: https://www.youtube.com/channel/UC-jHioVmLr8Cb1lFBIZD2hQ/

When I try to make the API call to retrieve the "uploads" playlist, it succeeds, but returns an empty playlist.

Finding the uploads playlist via https://www.googleapis.com/youtube/v3/channels?part=contentDetails&id=UC-jHioVmLr8Cb1lFBIZD2hQ (API key omitted) returns

{
    "kind": "youtube#channelListResponse",
    "etag": "\"XpPGQXPnxQJhLgs6enD_n8JR4Qk/SQbT6DxUQ-PRgTma_VN0xA8OmHE\"",
    "pageInfo": {
        "totalResults": 1,
        "resultsPerPage": 1
    },
    "items": [
        {
            "kind": "youtube#channel",
            "etag": "\"XpPGQXPnxQJhLgs6enD_n8JR4Qk/m44G0g4BqX0Af7CaFKoFcqJDqm0\"",
            "id": "UC-jHioVmLr8Cb1lFBIZD2hQ",
            "contentDetails": {
                "relatedPlaylists": {
                    "uploads": "UU-jHioVmLr8Cb1lFBIZD2hQ",
                    "watchHistory": "HL",
                    "watchLater": "WL"
                }
            }
        }
    ]
}

but retrieving the items in the uploads playlist via https://www.googleapis.com/youtube/v3/playlistItems?playlistId=UU-jHioVmLr8Cb1lFBIZD2hQ&part=id,contentDetails&maxResults=50 returns

{
    "kind": "youtube#playlistItemListResponse",
    "etag": "\"XpPGQXPnxQJhLgs6enD_n8JR4Qk/E0c9LqWjuNHvL-UjCIKS4N9Fn5M\"",
    "pageInfo": {
        "totalResults": 0,
        "resultsPerPage": 50
    },
    "items": []
}

I would like to be able to just pull the videos that show up from the videos tab, but cannot seem to do that with the API.

Benjamin Loison
  • 3,782
  • 4
  • 16
  • 33
  • When channel had no uploads, videos-tab used to show the liked videos of that channel. Nowadays videos-tab just shows "no videos" in that case, as liked videos are now always private. – Markus Laire Sep 03 '20 at 16:57
  • As this channel seems to now have videos, sharing another channel that has the issue seems required (if any exists). – Benjamin Loison Jun 10 '23 at 09:21

1 Answers1

0

The reason why you don't have results is because that YouTube channel (i.e. HRVY) hasn't uploaded videos (yet).

You can check the uploaded videos page from HRVY channel.


There, you can see that no videos are uploaded, but you might wonder: how this is possible if I can see videos on this channel?

Unfortunately, I can't say for sure why this happened, but, if you still wants to retrieve the videos from that channel, retrieve videos from a specific playlist by using the playlistId and not the uploads id.

For example, the "Most Popular" playlist from that channel has its playlistId: PLtz80rG4U0K99mMxPLNFPhwBIKkvzx9x1.

Benjamin Loison
  • 3,782
  • 4
  • 16
  • 33
Mauricio Arias Olave
  • 2,259
  • 4
  • 25
  • 70
  • Yes I noticed that there are no uploads, I want to be able to get all the videos that would be displayed under the videos tab on YouTube. Official Artist Channels like this one have videos there that are actually uploaded by other channels. – Gibran Essa Jun 11 '19 at 18:53
  • @GibranEssa then, with my answer you can do that. – Mauricio Arias Olave Jun 15 '19 at 16:37