1.0.11 • Published 6 years ago
megu-randbooru v1.0.11
Megu-Randbooru
I have created this module for ease of use in some of my projects, however you are free to use it! It has two modes, SFW and NSFW.
- SFW grabs from safebooru, guaranteeing lack of NSFW content.
- NSFW grabs from gelbooru, NSFW is there, but you must add the correct tags if you want it guaranteed.
Usage:
const randbooru = require('megu-randbooru');
const bg = new randbooru.BooruGrabber("sfw");//nsfw to use Gelbooru
bg.randomImage("megumin").then(data=>{
console.log(data);
}).catch(err=>{
console.log(err);
})
randomImage response:
{
image_url: 'link_to_image',
source_url: 'link_to_post'
}
- Made by Megumin
- https://krisdev.me