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 🙏

© 2024 – Pkg Stats / Ryan Hefner

asuna-anime-api

v1.1.1

Published

An api for searching download links, streaming links, pages of your favorite animes

Downloads

7

Readme

ANIME-API

Last version npm Last version Node version Travis Coverage Status Dependency status Last version XO code style

Star the project

Are you not tired of searching where you can watch or download your favorite animes ? To search on hundred of website until you find what you are looking for ? If yes, this API is for you. This API is a powerful scraper of many streaming and downloading website. With this API, you can search a page about your favorite anime or search for a download link or streaming link for enjoying your favorite animes.

npm install asuna-anime-api

Short Example

If you want to search for a streaming link of the episode 387 of naruto shippuden

const animeapi = require('asuna-anime-api');
const download = await animeapi.download('naruto shippuden', 387);

Features

  • Get page links: Get the page links of the anime on many website by searching an anime by name

  • Get streaming links: Get the streaming link of an episode of an anime by anime name

  • Get download links: Get the direct download link of an episode of an anime by anime name

API

Search page link by anime name

async links(search, options)

| name | type | description | | :--- | :---------- | :--- | | search | String | name of the anime searched | | options | Object | (optionnal) List of the options |

Lists of optionnal options available for page links

| name of key | return type | description | | :--- | :---------- | :--- | | limit_per_website | Number | Limit the number of result per website | | limit | Number | Limit the number of total result | | website | String | Website that you wanna target, see under for the complete list |

Format response of links

| name of key | return type | description | | :--- | :---------- | :--- | | source | String | Name of the source | | title | String | Complete title of the anime on the website | | link | String | Link of the anime| | levenshtein | Number | Difference of character from the search |

The result is order by levenshtein. The first result will be the closest from your research.

Search streaming links by anime name

async stream(search, episode, options)

| name | type | description | | :--- | :---------- | :--- | | search | String | name of the anime searched | | episode | Number | number of the episode searched | | options | Object | (optionnal) List of the options |

Lists of optionnal options available for stream links

| name of key | return type | description | | :--- | :---------- | :--- | | limit_per_website | Number | Limit the number of result per website |

Format response of stream

| name of key | return type | description | | :--- | :---------- | :--- | | source | String | Name of the source | | link | String | Link of the stream |

Only one result by source will be provided.

Search downloading links by anime name

async download(search, episode, options)

| name | type | description | | :--- | :---------- | :--- | | search | String | name of the anime searched | | episode | Number | number of the episode searched | | options | Object | (optionnal) List of the options |

Lists of optionnal options available for download links

| name of key | return type | description | | :--- | :---------- | :--- | | limit_per_website | Number | Limit the number of result per website |

Format response of download

| name of key | return type | description | | :--- | :---------- | :--- | | source | String | Name of the source | | link | String | Link of the download |

Only one result by source will be provided.

List of website available

The list below show the website scraped by the API and the website available for the option website

| website variable | website url | | :--- | :---------- | | ANIMELAND | https://www.animeland.us/ | | CHIA-ANIME | http://www.chia-anime.me/ | | ANIMEOUT | https://www.animeout.xyz/ | | GOGOANIME | https://www3.gogoanime.pro/ | | ANIMEFREAK | https://www.animefreak.tv/ | | ANIME8 | https://anime8.ru/ | | 9ANIME | http://9anime.to/ | | ANIMEDAISUKI | https://animedaisuki.moe/ |

The list is increasing slowly. I am working on it.

Examples

const animeapi = require('asuna-anime-api');
const results = await animeapi.links('Naruto shippuden');
results = [{
    source: 'ANIMELAND',
    title: 'Naruto Shippuden',
    link: 'https://www.animeland.us/dub/naruto-shippuden',
    levenshtein: 2
  },
  {
    source: 'CHIA-ANIME',
    title: 'Naruto Shippuden',
    link: 'http://www.chia-anime.me/episode/naruto%e3%83%8a%e3%83%ab%e3%83%88%e7%96%be%e9%a2%a8%e4%bc%9danime/',
    levenshtein: 7
  },
  {
    source: 'ANIMEOUT',
    title: 'Naruto Shippuden Movie 7 The Last',
    link: 'https://www.animeout.xyz/dub/naruto-shippuden-movie-7-the-last',
    levenshtein: 19
}]
const animeapi = require('asuna-anime-api');
const stream = await animeapi.stream('naruto shippuden', 387);
results = [{
    source: 'ANIMELAND',
    link: 'https://www.animeland.us/naruto-shippuden-episode-500-english-dubbed'
  },
  {
    source: 'CHIA-ANIME',
    link: 'http://www.chia-anime.me/naruto-shippuden-episode-500-english-subbed/'
}]
const animeapi = require('asuna-anime-api');
const download = await animeapi.download('naruto shippuden', 387, {website: 'CHIA-ANIME'});
results = [{
  {
    source: 'CHIA-ANIME',
    link: 'http://www.chia-anime.me/naruto-shippuuden-episode-387-english-subbed/'
}]

How to contribute/test

For testing, install the node project and run the test command.

node install
npm test

Also, you can use the command under for running the test without the linter

npm run test-no

The API has two kind of tests.

  1. dynamic : Perform query on the real Website.
  2. static : Run the API through website mock, allowing the tests to be more precise.

I am also using winston for filling up logs.

License

MIT - Copyright © JUSTAL Kevin