Pausing/ Resuming all torrents: qb.pause_all() Qb.download_from_link(my_magnet_uri, category='anime') Qb.download_from_link(my_magnet_uri, savepath=dl_path)Īpplying labels to downloads: qb.download_from_file(myfile, label='secret-files ) ') Qb.download_from_file(myfile, savepath=dl_path) Specifing save path for downloads: dl_path = '/home/user/Downloads/special-dir/' # method will always return empty JSON object.ĭownload multipe torrents by list of links: link_list = ĭownloading torrents by file: torrent_file = open('my-torrent-file.torrent', 'rb')ĭownloading multiple torrents by using files: torrent_file_list = Downloading torrentsĭownload torrents by link: magnet_link = "magnet:?xt=urn:btih:e334ab9ddd91c10938a7." Refer qBittorents WEB API documentation for all possible filters. # This will return all paused torrents sorted by their Leech:Seed ratio. Qb.torrents(filter='paused', sort='ratio') # downloading and are labeled as ``my category``. # This will return all torrents which are currently from qbittorrent import Client qb = Client ( '', verify = False ) API methods Getting torrentsįilter torrents: qb.torrents(filter='downloading', category='my category') This can be done by passing verify=False while initializing the Client. If you have enabled SSL and are using a self-signed certificate, you’d probably want to disable SSL verification. torrents () for torrent in torrents : print torrent # to use defaults, just do qb.login() torrents = qb. login ( 'admin', 'your-secret-password' ) # not required when 'Bypass from localhost' setting is active. How to enable the qBittorrent Web UI Quick usage guide from qbittorrent import Client qb = Client ( '' ) qb. QBittorent webUI must be enabled before using this API client. You can also stay on the bleeding edge of the package: $ git clone The best way is to install a stable release from PyPI: $ pip install python-qbittorrent It’ll be best if you upgrade your client to a latest version. Some methods are only supported in qBittorent’s latest version (v3.3.1 when writing). This wrapper is based on the methods described in qBittorrent’s Official Web API Documentation Python wrapper for qBittorrent Web API (for versions above 4.1, for version below and above v3.1.x please use 0.3.1 version).įor qBittorrent clients with earlier versions, use mookfist’s python-qbittorrent.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |