Replies: 2 comments
-
Counterpart can be identified via get_watch_playlist: https://ytmusicapi.readthedocs.io/en/stable/reference.html#ytmusicapi.YTMusic.get_watch_playlist BrowseId vs VideoId (the MPRE.. is a browseId): https://ytmusicapi.readthedocs.io/en/stable/faq.html#what-is-a-browseid In general, use an authenticated instance if you want to get only songs. Does this help? |
Beta Was this translation helpful? Give feedback.
-
It's true that using a unauthorized user returns |
Beta Was this translation helpful? Give feedback.
-
I'm willing to get a list of official videos for my music library. Those that appear in the "Song/Video" tab switch sometimes.
So far no luck. I have even tried debugging the browser page to find when the "Video" switch becomes active, and how it knows the video ID, but it doesn't look openly available in the responses.
I got a list of all my songs in the library (just "Google download / takeout" feature), so I have their IDs.
The thing that might work, but kind of ugly and not fully tested, is to get the album id for each song, and then use the
get_album()
call - and only then theMUSIC_VIDEO_TYPE_OMV
value appears. Otherwise, when I doget_song()
call, there's no indication of video being available. Also those "MUSIC_VIDEO_TYPE_" seem to be not what I'd expect.What I have also noticed is that the IDs produced by
get_album()
are different from what the YTmusic website uses, and they seem to be the ids of the actual corresponding videos.For example, what I use for testing: there's a song
-vIAjs5nGFo
and the album id for it isMPREb_8XwWknRIRMO
. And when I doget_album()
, I get a different ID for this song,MtHEiuuYt8k
(which happens to be the actual video id as well).Any suggestions about this confusion and about the easiest way of finding the videos for songs?
Beta Was this translation helpful? Give feedback.
All reactions