qobuz-dl icon indicating copy to clipboard operation
qobuz-dl copied to clipboard

Download purchased music without active subscription

Open ThomasAH opened this issue 11 months ago • 6 comments

I regularly buy albums on Qobuz. In 2023 the official Qobuz downloader app for Windows was introduced and the former option of downloading .tar archives via their web interface has been removed, so Linux users can only download single tracks via the web interface.

qobuz-dl has helped me very much, as I can conveniently download purchased music. Thank you! But by default it aborts with the message "Free accounts are not eligible to download tracks.", so I had to patch qopy.py to make it work:

--- qopy.py.orig
+++ qopy.py
@@ -122,12 +122,12 @@
 
     def auth(self, email, pwd):
         usr_info = self.api_call("user/login", email=email, pwd=pwd)
-        if not usr_info["user"]["credential"]["parameters"]:
-            raise IneligibleError("Free accounts are not eligible to download tracks.")
+        #if not usr_info["user"]["credential"]["parameters"]:
+        #    raise IneligibleError("Free accounts are not eligible to download tracks.")
         self.uat = usr_info["user_auth_token"]
         self.session.headers.update({"X-User-Auth-Token": self.uat})
-        self.label = usr_info["user"]["credential"]["parameters"]["short_label"]
-        logger.info(f"{GREEN}Membership: {self.label}")
+        #self.label = usr_info["user"]["credential"]["parameters"]["short_label"]
+        #logger.info(f"{GREEN}Membership: {self.label}")
 
     def multi_meta(self, epoint, key, id, type):
         total = 1

For tracks I do not have purchased, I get "Demo. Skipping", which is absolutely fine, so in my opinion there shouldn't be a reason to abort on accounts without a subscription. Maybe print a warning like "Free accounts are only eligible to download purchased tracks." instead?

ThomasAH avatar Mar 29 '24 09:03 ThomasAH

It works for me, thank you !

Maybe print a warning like "Free accounts are only eligible to download purchased tracks." instead?

I totally agree

Saimyx avatar Apr 10 '24 11:04 Saimyx

Thank you for the patch, I just purchased several albums and the presented option of downloading tracks one by one is not good. So I found this tool and made the above change in order to grab my purchases. :)

danopia avatar May 13 '24 13:05 danopia

Thank you! Works flawlessly! Finally a work around for the lack of Qobuz Downloader on Linux!

lypanov avatar Jun 04 '24 19:06 lypanov

For some reason I get "Demo. Skipping" even for tracks I have purchased. Any idea about why this might be?

Rapakko avatar Jun 23 '24 21:06 Rapakko

For some reason I get "Demo. Skipping" even for tracks I have purchased. Any idea about why this might be?

Just tested, it still works fine for me with both, purchased albums and purchased tracks.

When I'm clicking on a purchased track in the web player, the page still displays the full album URL and qobuz-dl shows "Demo. Skipping" for all tracks except the purchased one. You could use the three dots menu and "share" the track to see a URL for the single track that works with qobuz-dl.

Can you see the purchased album or track in https://play.qobuz.com/user/library/purchases/albums or https://play.qobuz.com/user/library/purchases/tracks? Edit: And are you logged in with the same user account in qobuz-dl as you are in the web interface?

ThomasAH avatar Jun 24 '24 11:06 ThomasAH