Open yami-no-tusbas opened 1 year ago
here is an exemple of response from the API :
<posts limit="1" offset="0" count="246448">
<post>
<id>7956269</id>
<created_at>Thu Nov 24 08:30:35 -0600 2022</created_at>
<score>0</score>
<width>1417</width>
<height>1417</height>
<md5>803d299be841d0d4da46bda2ffca5343</md5>
<directory>80/3d</directory>
<image>803d299be841d0d4da46bda2ffca5343.png</image>
<rating>general</rating>
<source>https://itukai.tumblr.com/post/701782109617094656</source>
<change>1669300237</change>
<owner>danbooru</owner>
<creator_id>6498</creator_id>
<parent_id>0</parent_id>
<sample>1</sample>
<preview_height>250</preview_height>
<preview_width>250</preview_width>
<tags>
1boy 1girl :| ankle_socks backlighting bag bag_on_lap bag_removed bangs bench black_footwear black_pants black_socks blue_necktie blue_skirt blue_sky blue_theme blush book brown_hair closed_mouth cloud cloudy_sky collared_shirt diagonal-striped_necktie diagonal_stripes dot_nose downscaled eye_contact floating_hair hair_behind_ear highres holding holding_bag holding_book horizon itunohika legs_apart loafers looking_at_another looking_to_the_side morning necktie ocean on_bench open_book original outdoors pants park_bench parted_lips pleated_skirt reading resized road road_sign scenery school_bag school_uniform shade shadow shirt shirt_tucked_in shoes short_hair short_sleeves sidewalk sign signature sitting_on_bench skirt sky socks standing street striped striped_necktie tareme water white_shirt wide_shot wind wing_collar wooden_bench
</tags>
<title/>
<has_notes>false</has_notes>
<has_comments>false</has_comments>
<file_url>
https://img3.gelbooru.com/images/80/3d/803d299be841d0d4da46bda2ffca5343.png
</file_url>
<preview_url>
https://img3.gelbooru.com/thumbnails/80/3d/thumbnail_803d299be841d0d4da46bda2ffca5343.jpg
</preview_url>
<sample_url>
https://img3.gelbooru.com/samples/80/3d/sample_803d299be841d0d4da46bda2ffca5343.jpg
</sample_url>
<sample_height>850</sample_height>
<sample_width>850</sample_width>
<status>active</status>
<post_locked>0</post_locked>
<has_children>false</has_children>
</post>
</posts>
The gelbooru api is unfortunately completely different than danboorus. I'll begin work on it, but I suspect it may take some time.
Thank you !
I don't have danbooru account, and don't want to, is it possible to support Gelbooru ?
Error logs :
I tried added gelbooru, not supported, tried to fallback on danbooru, did not work I assume because I don't have credentials.
JSON Code :
{"active": "Gelbooru", "negativeprompt": "lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, normal quality, jpeg artifacts, signature, watermark, username, blurry, artist name", "boorus": [{"name": "Danbooru", "host": "https://danbooru.donmai.us", "username": "", "apikey": ""}, {"name": "AIBooru", "host": "https://aibooru.space", "username": "", "apikey": ""}, {"name": "Gelbooru", "host": "https://gelbooru.com", "username": "censored", "apikey": "censored"}]}
Bruh, I just tested with danbooru, limited to 2 tags... not really usefull to search with, Gelbooru don't have such stupids limitations...
Here is the query for gelbooru :
https://gelbooru.com/index.php?page=dapi&s=post&q=index&limit=6&pid=0&tags=-animated%201girl%20rating%3Ageneral (credential are send on POST form) OR
https://gelbooru.com/index.php?page=dapi&s=post&q=index&limit=6&pid=0&tags=-animated 1girl rating%3Ageneral&user_id=__ID__&api_key=__API_KEY__
This would return an xml-like file like danbooru.