Quantcast
Channel: Active questions tagged youtube-api - Stack Overflow
Viewing all articles
Browse latest Browse all 3831

Youtube Playlists API pageInfo.totalResults and items are inconsistent

$
0
0

The Youtube Playlists APIplaylistResponse.pageInfo.totalResults and playlistResponse.items are inconsistent.

pageInfo.totalResults includes the “Liked videos” playlist, however, items does not include this playlist.

This issue is easier to observe if the number of playlists in the account is less than maxResults.

Call the list method with the following request parameters:

  • maxResults: 50
  • mine: true

Actual result:totalResults includes the "Liked Videos" playlist. For example, if the user has 7 playlists, totalResults is 8 as it includes “Liked videos”

Expected result: Either totalResults does not include the “Liked videos” playlist, or items does.

For example, I have 7 playlists, 8 including "Liked Videos". Here totalResults includes the "Liked Vidoes" playlist, whereas items does not.

{"kind": "youtube#playlistListResponse","etag": "MRBqnBy-Y8RQ0TpqYmpqAE_05Lw","nextPageToken": "CAUQAA","pageInfo": {"totalResults": 8,"resultsPerPage": 7  },"items": [    {"kind": "youtube#playlist","etag": "5-eWNGtmTPD4efCrIJvSCJwbYfE","id": "ozfDHFjXSdWdBqXDbH0W"    },    {"kind": "youtube#playlist","etag": "vAMuqE_49abzgSQTTSroegIi2xU","id": "tglNJQrU86MyB7b3iqH5"    },    {"kind": "youtube#playlist","etag": "D5Yv5VC-ZJ5wrJ6BV6Wbv0cSVXw","id": "6zz7DncBpOw8Uzx0hYeV"    },    {"kind": "youtube#playlist","etag": "OyI6XYGqAITCIBIgNZhKZh9akXs","id": "Zbz6LcJlQYc2l3Wt73kr"    },    {"kind": "youtube#playlist","etag": "Mexdqkd9YgKdOcMtRM8joax6Jfs","id": "UjcPmVI0zukbmnvWXiEi"    },    {"kind": "youtube#playlist","etag": "Mexdqkd9YgKdOcMtRM8joax6Jfs","id": "p6ocnzio8hKNKAe85m6m"    },    {"kind": "youtube#playlist","etag": "Mexdqkd9YgKdOcMtRM8joax6Jfs","id": "OXCW0pdVWeYLjPsXN1mA"    }  ]}

Viewing all articles
Browse latest Browse all 3831

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>