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

@nqbt/core

v0.1.1

Published

TypeScript qBittorrent WebUI API binding

Readme

@nqbt/core

version CI

TypeScript qBittorrent WebUI API binding.

Installation

npm i @nqbt/core

Usage

import { QBittorrent } from '@nqbt/core';

const client = new QBittorrent({
  baseURL: 'http://localhost:9091/api/v2',
  username: 'admin',
  password: 'adminadmin'
});

await client.login();

const version = await client.getApplicationVersion();
console.log('qBittorrent version:', version);

const torrents = await client.getTorrentList({
  filter: 'downloading',
  sort: 'dlspeed',
  reverse: true,
  limit: 10
});

console.log('downloading torrents:', torrents.length);

if (torrents[0]) {
  // qBittorrent v5 uses stop/start; v4 uses pause/resume.
  // Both method pairs are kept and auto-switch internally.
  await client.stopTorrents(torrents[0].hash);
  await client.startTorrents(torrents[0].hash);

  // Equivalent aliases:
  // await client.pauseTorrents(torrents[0].hash);
  // await client.resumeTorrents(torrents[0].hash);
}

await client.addNewMagnet('magnet:?xt=urn:btih:<YOUR_INFO_HASH>', {
  category: 'demo',
  tags: 'sample',
  paused: true
});

await client.logout();

Reference

Official docs:

Support TypeScript API:

| Category | TypeScript API | WebUI API | | --- | --- | --- | | Authentication | login | login | | Authentication | logout | logout | | Application | getApplicationVersion | get-application-version | | Application | getApiVersion | get-api-version | | Application | getBuildInfo | get-build-info | | Application | getApplicationPreferences | get-application-preferences | | Application | setApplicationPreferences | set-application-preferences | | Application | getDefaultSavePath | get-default-save-path | | Application | shutdownApplication | shutdown-application | | Application | getCookies | get-cookies | | Application | setCookies | set-cookies | | Log | getLog | get-log | | Log | getPeerLog | get-peer-log | | Sync | getMainData | get-main-data | | Sync | getTorrentPeersData | get-torrent-peers-data | | Transfer info | getGlobalTransferInfo | get-global-transfer-info | | Transfer info | getAlternativeSpeedLimitsState | get-alternative-speed-limits-state | | Transfer info | toggleAlternativeSpeedLimits | toggle-alternative-speed-limits | | Transfer info | getGlobalDownloadLimit | get-global-download-limit | | Transfer info | setGlobalDownloadLimit | set-global-download-limit | | Transfer info | getGlobalUploadLimit | get-global-upload-limit | | Transfer info | setGlobalUploadLimit | set-global-upload-limit | | Transfer info | banPeers | ban-peers | | Torrent Management | getTorrentList | get-torrent-list | | Torrent Management | getTorrentGenericProperties | get-torrent-generic-properties | | Torrent Management | getTorrentTrackers | get-torrent-trackers | | Torrent Management | getTorrentWebSeeds | get-torrent-web-seeds | | Torrent Management | getTorrentContents | get-torrent-contents | | Torrent Management | getTorrentPiecesStates | get-torrent-pieces-states | | Torrent Management | getTorrentPiecesHashes | get-torrent-pieces-hashes | | Torrent Management | stopTorrents / pauseTorrents | stop-torrents | | Torrent Management | startTorrents / resumeTorrents | resume-torrents | | Torrent Management | deleteTorrents | delete-torrents | | Torrent Management | recheckTorrents | recheck-torrents | | Torrent Management | reannounceTorrents | reannounce-torrents | | Torrent Management | editTrackers | edit-trackers | | Torrent Management | removeTrackers | remove-trackers | | Torrent Management | addNewTorrent / addNewMagnet | add-new-torrent | | Torrent Management | addTrackersToTorrent | add-trackers-to-torrent | | Torrent Management | addPeers | add-peers | | Torrent Management | increaseTorrentPriority | increase-torrent-priority | | Torrent Management | decreaseTorrentPriority | decrease-torrent-priority | | Torrent Management | maximalTorrentPriority | maximal-torrent-priority | | Torrent Management | minimalTorrentPriority | minimal-torrent-priority | | Torrent Management | setFilePriority | set-file-priority | | Torrent Management | setTorrentShareLimits | set-torrent-share-limits | | Torrent Management | getTorrentDownloadLimit | get-torrent-download-limit | | Torrent Management | setTorrentDownloadLimit | set-torrent-download-limit | | Torrent Management | getTorrentUploadLimit | get-torrent-upload-limit | | Torrent Management | setTorrentUploadLimit | set-torrent-upload-limit | | Torrent Management | setTorrentLocation | set-torrent-location | | Torrent Management | setTorrentName | set-torrent-name | | Torrent Management | setTorrentCategory | set-torrent-category | | Torrent Management | setAutomaticTorrentManagement | set-automatic-torrent-management | | Torrent Management | toggleSequentialDownload | toggle-sequential-download | | Torrent Management | setFirstLastPiecePriority | set-firstlast-piece-priority | | Torrent Management | setForceStart | set-force-start | | Torrent Management | setSuperSeeding | set-super-seeding | | Torrent Management | getAllCategories | get-all-categories | | Torrent Management | addNewCategory | add-new-category | | Torrent Management | editCategory | edit-category | | Torrent Management | removeCategories | remove-categories | | Torrent Management | addTorrentTags | add-torrent-tags | | Torrent Management | removeTorrentTags | remove-torrent-tags | | Torrent Management | getAllTags | get-all-tags | | Torrent Management | createTags | create-tags | | Torrent Management | deleteTags | delete-tags | | Torrent Management | renameFile | rename-file | | Torrent Management | renameFolder | rename-folder |

Compatibility note

  • stopTorrents and pauseTorrents are both available; both auto-switch to /torrents/stop (v5) or /torrents/pause (v4).
  • startTorrents and resumeTorrents are both available; both auto-switch to /torrents/start (v5) or /torrents/resume (v4).

Related

This package is used to power AnimeSpace, offering a comprehensive solution for automatically following bangumis. It can fetch anime resources, download desired video content, and upload them to the local file system or remote WebDAV server. The downloading process is facilitated by this package.

Credits

License

MIT License © 2025 XLor