A nodejs wrapper for moebooru-like APIs
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
cCurmudgeon 75bd9b6961 1.1.6 8 hours ago
src test 8 hours ago
.gitignore initial 1 month ago
README.md npm listed 2 weeks ago
package-lock.json 1.1.6 8 hours ago
package.json 1.1.6 8 hours ago

README.md

Haruna

A node-js battleship that wraps around moebooru-like API.

Supports these websites for now:

konachan
yande.re

const haruna = require("./index");
const haru = new haruna();
haru
  .posts(1, "Azur Lane")
  .then((data) => console.log(data))
  .catch((error) => console.log(error.message));

Functions

Posts

posts(website, keyword, page, limit, order, rating);

Parameters

const baseurl = {
  1: "https://konachan.com",
  2: "https://yande.re",
};
const types = {
  1: "/post.json",
  2: "/comments.json",
  3: "/note.json",
  4: "/artist.json",
  5: "/tag.json",
  6: "/pool.json",
  7: "/forum.json",
};
const orders = {
  1: "score",
  2: "favorited",
  3: "wide",
  4: "nonwide",
};
const ratings = {
  1: "safe",
  2: "questionable",
  3: "explicit",
  4: "questionableplus",
  5: "questionableless",
};