I am exploring ytmusicapi and facing issue while creating playlist. I am using browser authentication and I have stored the json in a file named browser.json. The format of the content is same as provided in the manual file creation documentation. But when I try to search for songs using the same object, it works perfectly fine. So I don't think its an issue related to Cookie.
Describe the bug
Getting ytmusicapi.exceptions.YTMusicServerError: Server returned HTTP 401: Unauthorized. while creating playlist.
Code:
I am exploring ytmusicapi and facing issue while creating playlist. I am using browser authentication and I have stored the json in a file named
browser.json
. The format of the content is same as provided in the manual file creation documentation. But when I try to search for songs using the same object, it works perfectly fine. So I don't think its an issue related to Cookie.Describe the bug Getting
ytmusicapi.exceptions.YTMusicServerError: Server returned HTTP 401: Unauthorized.
while creating playlist. Code:browser.json:
{ "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:72.0) Gecko/20100101 Firefox/72.0", "Accept": "*/*", "Accept-Language": "en-US,en;q=0.5", "Content-Type": "application/json", "X-Goog-AuthUser": "0", "x-origin": "https://music.youtube.com", "Cookie" : "<COOKIE GOES HERE>" }
Respose:
To Reproduce Steps to reproduce the behavior: Try the code provided in the above screenshot
Please let me know how can i resolve this, I am working on my personal project and would love any kind of help. Thanks a lot