See qBittorrent's API documentation for more info.
Login to qBittorrent
Name | Type | Description | |
---|---|---|---|
host | string |
Host name of your qBittorrent instance | |
username | string |
Username used to access the WebUI | |
password | string |
Password used to access the WebUI |
Promise<Object>
API methods
Get application version
Promise<string>
The response is a string with the application version, e.g. v4.1.3
Get API version
Promise<string>
The response is a string with the WebAPI version, e.g. 2.0
Get build info
Promise<BuildInfo>
Object containing build info
Shutdown application
Void
Get application preferences
Promise<Preferences>
Object containing the application's settings
Get default save path
Promise<string>
Default save path, e.g. C:/Users/Dayman/Downloads
Get log
Name | Type | Description | |
---|---|---|---|
normal | boolean |
Include normal messages (default: true ) |
|
info | boolean |
Include info messages (default: true ) |
|
warning | boolean |
Include warning messages (default: true ) |
|
critical | boolean |
Include critical messages (default: true ) |
|
lastKnownId | number |
Exclude messages with "message id" <= lastKnownId (default: -1 ) |
Promise<Array<Log>>
Logs
Get peer log
Name | Type | Description | |
---|---|---|---|
lastKnownId | number |
Exclude messages with "message id" <= lastKnownId (default: -1 ) |
Promise<Array<PeerLog>>
Peer logs
Get main data
Name | Type | Description | |
---|---|---|---|
rid | number |
Response ID. If not provided, rid=0 will be assumed. If the given rid is different from the one of last server reply, full_update will be true |
Promise<MainData>
Main data
Get torrent peers data
Name | Type | Description | |
---|---|---|---|
hash | string |
Torrent hash | |
rid | number |
Response ID. If not provided, rid=0 will be assumed. If the given rid is different from the one of last server reply, full_update will be true |
Promise<PeerData>
Peer data
Get global transfer info
Promise<TransferInfo>
Transfer info
Get alternative speed limits state
Promise<number>
The response is 1 if alternative speed limits are enabled, 0 otherwise
Toggle alternative speed limits
Void
Get global download limit
Promise<number>
Current global download speed limit in bytes/second; this value will be zero if no limit is applied
Set global download limit
Name | Type | Description | |
---|---|---|---|
limit | number |
The global download speed limit to set in bytes/second |
Void
Get global upload limit
Promise<number>
Current global upload speed limit in bytes/second; this value will be zero if no limit is applied
Set global upload limit
Name | Type | Description | |
---|---|---|---|
limit | number |
The global upload speed limit to set in bytes/second |
Void
Ban peers
Name | Type | Description | |
---|---|---|---|
peers | string |
The peer to ban, or multiple peers separated by a pipe ` | . Each peer is a colon-separated host:port` |
Void
Get torrent list
Name | Type | Description | |
---|---|---|---|
filter | string |
Filter torrent list | |
category | string |
Get torrents with the given category (empty string means "without category"; null parameter means "any category") | |
sort | string |
Sort torrents by given key | |
reverse | boolean |
Enable reverse sorting | |
limit | number |
Limit the number of torrents returned | |
offset | number |
Set offset (if less than 0, offset from end) | |
hashes | string |
Filter by hashes. Can contain multiple hashes separated by |
Promise<Array<Torrent>>
Torrents
Get torrent generic properties
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent you want to get the generic properties of |
Promise<TorrentInfo>
Torrent properties
Get torrent trackers
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent you want to get the trackers of |
Promise<Array<Tracker>>
Torrent trackers
Get torrent webseeds
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent you want to get the webseeds of |
Promise<Array<Webseed>>
Torrent webseeds
Get torrent contents
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent you want to get the contents of |
Promise<Array<Content>>
Torrent contents
Get torrent pieces' states
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent you want to get the pieces' states of |
Promise<Array<number>>
States (integers) of all pieces (in order) of the torrent
Get torrent pieces' hashes
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent you want to get the pieces' hashes of |
Promise<Array<string>>
Hashes (strings) of all pieces (in order) of the torrent
Pause one or several torrents
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to pause. It can contain multiple hashes separated by | , to pause multiple torrents, or set to 'all', to pause all torrents |
Void
Resume one or several torrents
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to resume. It can contain multiple hashes separated by | , to resume multiple torrents, or set to 'all', to resume all torrents |
Void
Delete one or several torrents
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to delete. It can contain multiple hashes separated by | , to delete multiple torrents, or set to 'all', to delete all torrents |
deleteFile | boolean |
If set to true , the downloaded data will also be deleted, otherwise has no effect |
Void
Recheck one or several torrents
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to recheck. It can contain multiple hashes separated by | , to recheck multiple torrents, or set to 'all', to recheck all torrents |
Void
Reannounce one or several torrents
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to reannounce. It can contain multiple hashes separated by | , to reannounce multiple torrents, or set to 'all', to reannounce all torrents |
Void
Edit trackers
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent | |
origUrl | string |
The tracker URL you want to edit | |
newUrl | string |
The new URL to replace the origUrl |
Void
Remove trackers
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent | |
url | string |
URLs to remove, separated by ` | ` |
Void
Add peers
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hash of the torrent, or multiple hashes separated by a pipe ` | ` |
peers | string |
The peer to add, or multiple peers separated by a pipe ` | . Each peer is a colon-separated host:port` |
Void
Add trackers to torrent
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent | |
urls | string |
URLs of the trackers, separated by a newline \n |
Void
Increase torrent priority
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to increase the priority of. It can contain multiple hashes separated by ` | `, to increase the priority of multiple torrents, or set to 'all', to increase the priority of all torrents |
Void
Decrease torrent priority
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to decrease the priority of. It can contain multiple hashes separated by ` | `, to decrease the priority of multiple torrents, or set to 'all', to decrease the priority of all torrents |
Void
Maximal torrent priority
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set to the maximum priority. It can contain multiple hashes separated by ` | `, to set multiple torrents to the maximum priority, or set to 'all', to set all torrents to the maximum priority |
Void
Minimal torrent priority
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set to the minimum priority. It can contain multiple hashes separated by ` | `, to set multiple torrents to the minimum priority, or set to 'all', to set all torrents to the minimum priority |
Void
Set file priority
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent | |
id | string |
File ids, separated by ` | ` |
priority | number |
File priority to set |
Void
Get torrent download limit
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents. It can contain multiple hashes separated by ` | ` or set to 'all' |
Void
Set torrent download limit
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set the download limit. It can contain multiple hashes separated by ` | `, to set the download limit of multiple torrents, or set to 'all', to set all torrents the download limit |
limit | string |
Download speed limit in bytes per second you want to set |
Void
Set torrent share limit
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set the share limit. It can contain multiple hashes separated by ` | `, to set the share limit of multiple torrents, or set to 'all', to set all torrents the share limit |
ratioLimit | string |
Max ratio the torrent should be seeded until. -2 means the global limit should be used, -1 means no limit |
|
seedingTimeLimit | string |
Max amount of time the torrent should be seeded. -2 means the global limit should be used, -1 means no limit |
Void
Get torrent upload limit
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents. It can contain multiple hashes separated by ` | ` or set to 'all' |
Void
Set torrent upload limit
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set the upload limit. It can contain multiple hashes separated by ` | `, to set the upload limit of multiple torrents, or set to 'all', to set all torrents the upload limit |
limit | string |
Upload speed limit in bytes per second you want to set |
Void
Set torrent location
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set the location. It can contain multiple hashes separated by ` | `, to set the location of multiple torrents, or set to 'all', to set all torrents the location |
location | string |
Location to download the torrent to. If the location doesn't exist, the torrent's location is unchanged |
Void
Set torrent name
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent | |
name | string |
New torrent name |
Void
Set torrent category
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set the category. It can contain multiple hashes separated by ` | `, to set the category of multiple torrents, or set to 'all', to set the category of all torrents |
category | string |
The torrent category you want to set |
Void
Get all categories
Promise<Categories>
Categories in JSON format
Add new category
Name | Type | Description | |
---|---|---|---|
category | string |
The category you want to create | |
savePath | string |
Save path of the category |
Void
Edit category
Name | Type | Description | |
---|---|---|---|
category | string |
The category you want to edit | |
savePath | string |
Save path of the category |
Void
Remove categories
Name | Type | Description | |
---|---|---|---|
categories | string |
Category you want to remove. It can contain multiple cateogies separated by a newline \n |
Void
Add torrent tags
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to add tags to. It can contain multiple hashes separated by ` | `, to add tags to multiple torrents, or set to 'all', to add the tags of all torrents |
tags | string |
The list of tags you want to add to passed torrents |
Void
Remove torrent tags
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to remove tags to. It can contain multiple hashes separated by ` | `, to remove tags to multiple torrents, or set to 'all', to remove the tags of all torrents |
tags | string |
Category you want to remove. It can contain multiple cateogies separated by a newline \n |
Void
Get all tags
Promise<Array<string>>
Tags
Create tags
Name | Type | Description | |
---|---|---|---|
tags | string |
List of tags you want to create. Can contain multiple tags separated by , |
Void
Delete tags
Name | Type | Description | |
---|---|---|---|
tags | string |
List of tags you want to delete. Can contain multiple tags separated by , |
Void
Set automatic torrent management
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set automatic torrent management. It can contain multiple hashes separated by ` | `, to set automatic torrent management of multiple torrents, or set to 'all', to set automatic torrent management of all torrents |
enable | boolean |
Enable automatic torrent management or not for the torrents listed in hashes |
Void
Toggle sequential download
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to toggle sequential download for. It can contain multiple hashes separated by ` | `, to toggle sequential download for multiple torrents, or set to 'all', to toggle sequential download for all torrents |
Void
Set first/last piece priority
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to toggle the first/last piece priority for. It can contain multiple hashes separated by ` | `, to toggle the first/last piece priority for multiple torrents, or set to 'all', to toggle the first/last piece priority for all torrents |
Void
Set force start
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set force start. It can contain multiple hashes separated by ` | `, to set force start of multiple torrents, or set to 'all', to set force start of all torrents |
value | boolean |
Enable force start or not for the torrents listed in hashes |
Void
Set super seeding
Name | Type | Description | |
---|---|---|---|
hashes | string |
The hashes of the torrents you want to set super seeding. It can contain multiple hashes separated by ` | `, to set super seeding of multiple torrents, or set to 'all', to set super seeding of all torrents |
value | boolean |
Enable super seeding or not for the torrents listed in hashes |
Void
Rename file
Name | Type | Description | |
---|---|---|---|
hash | string |
The hash of the torrent | |
id | number |
The id of the file to rename | |
name | string |
The new name to use for the file |
Void
Start search
Name | Type | Description | |
---|---|---|---|
pattern | string |
Pattern to search for (e.g. "Ubuntu 18.04") | |
plugins | string |
Plugins to use for searching (e.g. "legittorrents"). Supports multiple plugins separated by ` | `. Also supports 'all' and 'enabled' |
category | string |
Categories to limit your search to (e.g. "legittorrents"). Available categories depend on the specified plugins. Also supports 'all' |
Promise<SearchJob>
Search ID as JSON
Stop search
Name | Type | Description | |
---|---|---|---|
id | number |
ID of the search job |
Void
Get search status
Name | Type | Description | |
---|---|---|---|
id | number |
ID of the search job. If not specified, all search jobs are returned | Optional |
Promise<Array<SearchStatus>>
Status of the search jobs
Get search results
Name | Type | Description | |
---|---|---|---|
id | number |
ID of the search job | |
limit | number |
Max number of results to return. 0 or negative means no limit | Optional |
offset | number |
Result to start at. A negative number means count backwards (e.g. -2 returns the 2 most recent results) | Optional |
Promise<SearchResults>
Search results
Delete search
Name | Type | Description | |
---|---|---|---|
id | number |
ID of the search job |
Void
Get search categories
Name | Type | Description | |
---|---|---|---|
pluginName | string |
Name of the plugin (e.g. "legittorrents"). Also supports 'all' and 'enabled' | Optional |
Promise<Array<string>>
List of categories
Get search plugins
Promise<Array<SearchPlugin>>
List of plugins
Install search plugin
Name | Type | Description | |
---|---|---|---|
sources | string |
Url or file path of the plugin to install. Supports multiple sources separated by ` | ` |
Void
Uninstall search plugin
Name | Type | Description | |
---|---|---|---|
names | string |
Name of the plugin to uninstall (e.g. "legittorrents"). Supports multiple names separated by ` | ` |
Void
Enable search plugin
Name | Type | Description | |
---|---|---|---|
names | string |
Name of the plugin to enable/disable (e.g. "legittorrents"). Supports multiple names separated by ` | ` |
enable | boolean |
Whether the plugins should be enabled |
Void
Update search plugins
Void