summaryrefslogtreecommitdiffstats
path: root/gallery_dl/extractor/itaku.py
diff options
context:
space:
mode:
authorLibravatarUnit 193 <unit193@unit193.net>2025-04-27 20:34:08 -0400
committerLibravatarUnit 193 <unit193@unit193.net>2025-04-27 20:34:08 -0400
commit4a18b5837c1dd82f5964afcfc3fecc53cd97e79c (patch)
tree44019190a44fd449daa0efd07c65bbe524688c33 /gallery_dl/extractor/itaku.py
parentb830dc03b3b7c9dd119648e1be9c1145d56e096c (diff)
New upstream version 1.29.5.upstream/1.29.5
Diffstat (limited to 'gallery_dl/extractor/itaku.py')
-rw-r--r--gallery_dl/extractor/itaku.py24
1 files changed, 24 insertions, 0 deletions
diff --git a/gallery_dl/extractor/itaku.py b/gallery_dl/extractor/itaku.py
index 2974b59..e602665 100644
--- a/gallery_dl/extractor/itaku.py
+++ b/gallery_dl/extractor/itaku.py
@@ -65,6 +65,15 @@ class ItakuGalleryExtractor(ItakuExtractor):
return self.api.galleries_images(*self.groups)
+class ItakuStarsExtractor(ItakuExtractor):
+ subcategory = "stars"
+ pattern = BASE_PATTERN + r"/profile/([^/?#]+)/stars(?:/(\d+))?"
+ example = "https://itaku.ee/profile/USER/stars"
+
+ def posts(self):
+ return self.api.galleries_images_starred(*self.groups)
+
+
class ItakuImageExtractor(ItakuExtractor):
subcategory = "image"
pattern = BASE_PATTERN + r"/images/(\d+)"
@@ -139,6 +148,21 @@ class ItakuAPI():
}
return self._pagination(endpoint, params, self.image)
+ def galleries_images_starred(self, username, section=None):
+ endpoint = "/galleries/images/user_starred_imgs/"
+ params = {
+ "cursor" : None,
+ "stars_of" : self.user(username)["owner"],
+ "sections" : section,
+ "date_range": "",
+ "ordering" : "-date_added",
+ "maturity_rating": ("SFW", "Questionable", "NSFW"),
+ "page" : "1",
+ "page_size" : "30",
+ "visibility": ("PUBLIC", "PROFILE_ONLY"),
+ }
+ return self._pagination(endpoint, params, self.image)
+
def image(self, image_id):
endpoint = "/galleries/images/{}/".format(image_id)
return self._call(endpoint)