1.2.0 • Published 3 years ago

haruna-js v1.2.0

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

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",
};
1.2.0

3 years ago

1.1.6

3 years ago

1.1.5

3 years ago

1.1.4

3 years ago

1.1.3

3 years ago

1.1.2

3 years ago

1.1.0

3 years ago