npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

aniki

v1.4.9

Published

Node.js APIs wrapper for anime/manga related content.

Readme

Aniki

Node.js APIs wrapper for anime/manga related content.

See CHANGELOG for recent changes.

Table of contents

Aniki

Installation

With NPM:

npm i aniki@latest

With PNPM:

pnpm i aniki@latest

Available APIs

Bugs or suggestions

PLEASE let me know instantly if there are any mistakes / bugs by using the Issues.

If you want to suggest me anything, please also make an issue with the enhancement label.

Authentification

Important
If you need to authenticate with the APIs, you have to make your own authentification system, and use the basic fetch to use the auth, once you have made your system, you can use the access_tokens in the classes to make unrestricted requests.

Otherwise, for the MyAnimeList and MyMangaList, you can still use the client_id but it is recommended for tests only if requests appears in the client side.

Usage

Kitsu

const { AnimeKitsu } = require("aniki");
// ESM/TS
import { AnimeKitsu } from "aniki";

const anime = new AnimeKitsu();

// With an access_token
// If you have one, you'll be able to use the R18 rating category on the find and list age rating parameter.
// I do not take any responsibility for users who use the unrestricted content.
const anime = new AnimeKitsu("abCdEfgHiJK12345");

// Find anime in a simple way:
anime
  .find({ query: "Oshi no ko", offset: 0 })
  .then((r) => console.log(r.data[0]));

// All list from the first page (limited by 10 result)
anime.findMany({ offset: 0, limit: 10 }).then((results) => {
  console.log(results.data);
});

// Find anime with ID
anime.findUnique(2303).then((result) => {
  console.log(result.data);
});
// Alternative
anime.find(1733).then((result) => {
  console.log(result.data);
});

// Find an episode
anime.episode(2302).then((result) => {
  console.log(result.data);
});

// Using hooks
anime
  .find(
    { query: "Oshi no ko" },
    {
      beforeRequest: async (config) => {
        console.log("Before request with the url: " + config.url);
        // ...
      },
      onError: async (err, res) => {
        if (res.status === 404)
          console.error(`The requested content was not found!
    More details: ${(await err).errors[0].title}`);
        // ...
      },
      afterRequest: async (res) => {
        console.log("Request done!");
        // ...
      },
    },
  )
  .then((r) => console.log(r));

Warning
Using an access_token in the AnimeKitsu/MangaKitsu classes will unlock R18 (rule 18) features IN the API. THIS MODULE CAN RETRIEVE R18 CONTENT FROM THE API, MISUSE OF THOSE FEATURES IS AT YOUR OWN RISK. I DO NOT TAKE ANY RESPONSABILITY.

MyAnimeList

const { MyAnimeList } = require("aniki");

// ESM/TS
import { MyAnimeList } from "aniki";

// Using authentification
// Client ID.
const anime = new MyAnimeList({ client_id: "ClIENT_ID" });
// Access token
const anime = new MyAnimeList({ access_token: "ACCESS_TOKEN" });
// Both at the same time will not work.

// Fiding an anime
anime
  .find({ query: "Oshi no ko", offset: 0, limit: 10 })
  .then((r) => console.log(r.data[0])); // Return nodes.

// Getting the details of an anime
anime.details({ anime_id: 363 }).then((r) => console.log(r.id)); // Return anime details.
// Listing animes based on a specific rank
anime
  .ranking({ ranking_type: "tv", offset: 0, limit: 16 })
  .then((r) => console.log(r.data[0])); // Return nodes.

// Listing animes based on a year and a season of publication.
anime
  .seasonal({ year: 2009, season: "fall", offset: 0, limit: 16 })
  .then((r) => console.log(r.data[0])); // Return nodes.

// Almost the same for MyMangaList!

Note
I recommend to add any fields depending on your needs, if you don't specify the proper fields, some properties returned by the API will be undefined.

Example:

// Proper fields
anime
  .details(52991, ["created_at", "updated_at"])
  .then((r) =>
    console.log(r.id, r.title, new Date(r.created_at), new Date(r.updated_at)),
  ); // 52991, Sousou no Frieren, Date, Date

// Unproper fields
anime
  .details(52991, ["alternative_titles", "background"])
  .then((r) => console.log(r.id, r.title, r.mean)); // 52991, Sousou no Frieren, undefined.

Waifu.Im

const { WaifuIm } = require("aniki");

const waifu = new WaifuIm();

// Getting simple SFW maid images.
waifu
  .find({ isNsfw: "False", IncludedTags: "maid" })
  .then((r) => console.log(r));

Note
The isNsfw parameter is "False" by default.

License

MIT License - Normioffi