ncore-api-wrapper
v0.0.4-beta
Published
An ease-to-use wrapper for the non-existent nCore API
Downloads
8
Maintainers
Readme
nCore API Wrapper
:warning: Warning This package is still in beta (v0)! Until the full release most things can and probably will change so, don't build full apps around it yet!
nCore API Wrapper is a library that makes it easy to communicate with nCore including searching, downloading torrents and much more.
Features
- Beginner friendly 🚀
- Custom types 🔎
- Downloading torrents 📩
- Customizable useragent, cookies, etc... 🤖
- v1 and v2 API 🌎
- CommonJS and Module support 📦
- And much more! 🧪
Documentation 📚
In progress...
Installation ⌨️
To install nCore API Wrapper, simply run the following command:
npm install ncore-api-wrapper
Usage ❓
This is a simple overview of how to set up this library with all the options. Docs coming soon...
const nCore = require("ncore-api-wrapper");
const client = new nCore.Client({
cookies: new nCore.CookieManager().addCookiesFromString("Your Cookies"), //Log in with cookies
});
client.on("ready", async () => {
const torrent = await client.getTorrent(1490740);
console.log(torrent.title); //Le.fabuleux.destin.d.Amelie.Poulain.2001.1080p.BluRay.DD5.1.x264.HuN-LiLBOX
const output = require("fs")
.createWriteStream("Amelie csodálatos élete.torrent")(await torrent.download())
.pipe(output); //Download torrent
});
client.login(username, password); //Log in with username & password
Plans 📝
- [x] Torrent page parsing to JSON
- [x] Custom URL Query Manager
- [x] Custom Cookie Manager
- [x] Cookie Login
- [x] Communicating with
/ajax.php
- [x] Ajax response parsing to JSON
- [x] Torrent downloading
- [ ] v2 Search System
- [ ] v1 Search System
- [ ] User class instead of string usernames
Credits 🔎
- UnderCtrl for CommandKit's README
- brandon93s for html-table-to-json