Package to download from ncore.pro
Project description
Ncoreparser
Introduction
This module provides python API-s to manage torrents from ncore.pro eg.: search, download, rssfeed, etc..
Install
pip install ncoreparser
Examples
Search torrent Get most seeded torrents from all category
from ncoreparser import Client, SearchParamWhere, SearchParamType, ParamSort, ParamSeq
if __name__ == "__main__":
client = Client()
client.open("<username>", "<password>")
for t_type in SearchParamType:
torrent = client.search(pattern="", type=t_type, number=1,
sort_by=ParamSort.SEEDERS, sort_order=ParamSeq.DECREASING)[0]
print(torrent['title'], torrent['type'], torrent['size'], torrent['id'])
client.close()
Download torrent This example download Forest gump torrent file and save it to temp folder
from ncoreparser import Client, SearchParamWhere, SearchParamType, ParamSort, ParamSeq
if __name__ == "__main__":
client = Client()
client.open("<username>", "<password>")
torrent = client.search(pattern="Forrest gump", type=SearchParamType.SD_HUN, number=1,
sort_by=ParamSort.SEEDERS, sort_order=ParamSeq.DECREASING)[0]
client.download(torrent, "/tmp")
client.close()
Download torrent by rssfeed This example get all torrents and their informations from an ncore bookmark (rss feed)
from ncoreparser import Client
if __name__ == "__main__":
client = Client()
client.open("<username>", "<password>")
torrents = client.get_by_rss("<rss url>")
for torrent in torrents:
print(torrent['title'], torrent['type'], torrent['size'], torrent['id'])
client.close()
Get torrents by activity This example get all torrents and their informations from the Hit&run page
from ncoreparser import Client
if __name__ == "__main__":
client = Client()
client.open("<username>", "<password>")
torrents = client.get_by_activity()
for torrent in torrents:
print(torrent['title'], torrent['type'], torrent['size'], torrent['id'], torrent['rate'], torrent['remaining'])
client.close()
Get recommended torrents This example get all torrents and their informations from the recommended page
from ncoreparser import Client, SearchParamType
if __name__ == "__main__":
client = Client()
client.open("<username>", "<password>")
torrents = client.get_recommended(type=SearchParamType.SD_HUN)
for torrent in torrents:
print(torrent['title'], torrent['type'], torrent['size'], torrent['id'])
client.close()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for ncoreparser-1.7.2.linux-x86_64.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d14111d2efbb822785a085d04c5fb38b76af2df146007067cb5e7d3a74a12912 |
|
MD5 | 79eb8597249c61cf6d109a3f30b5b878 |
|
BLAKE2b-256 | f5cec8a61096673e369ef2ebe3c789301815257d8b74e9716ca4c40fc81982da |
Close
Hashes for ncoreparser-1.7.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fa16a0b0d988f03d92a0321dac1faa4639abd7e4d5585a802a84361eac6f82ad |
|
MD5 | f6721fbdc8bdd023bf5cd09e1f468261 |
|
BLAKE2b-256 | 14b195a9e9e33f27fdb69a2fa9360cdc445a493a98ebca6f80bfb817e5a565f1 |