According to [1], the downloaded video is AES-encrypted. Decryption key is stored locally in an IndexDB. I tried building a Python script using plyvel [2], a Python module for reading IndexDB/LevelDB, some time ago but IIRC, it had trouble reading the Chrome DB.
Maybe Google's dfindexeddb [3] works. I didn't try it, however.
It's not though. You can't download an mp4 to use however you wish with YouTube Premium. And definitely not via an API.
None of that was mentioned in the comment?
did you miss the word "API"? it was there.
AFAIK Premium allows you to download to persistent browser storage. But is it DRM-free/open or usable format?
It's DRM-ed and somewhat broken.
According to [1], the downloaded video is AES-encrypted. Decryption key is stored locally in an IndexDB. I tried building a Python script using plyvel [2], a Python module for reading IndexDB/LevelDB, some time ago but IIRC, it had trouble reading the Chrome DB. Maybe Google's dfindexeddb [3] works. I didn't try it, however.
[1] https://github.com/Marsel-marsel/youtube-premium-video-downl...
[2] https://github.com/wbolster/plyvel
[3] https://github.com/google/dfindexeddb