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.login("<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.logout()
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.login("<username>", "<password>")
torrent = client.search(pattern="Forrest gump", type=SearchParamType.HD_HUN, number=1,
sort_by=ParamSort.SEEDERS, sort_order=ParamSeq.DECREASING)[0]
client.download(torrent, "/tmp")
client.logout()
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.login("<username>", "<password>")
torrents = client.get_by_rss("<rss url>")
for torrent in torrents:
print(torrent['title'], torrent['type'], torrent['size'], torrent['id'])
client.logout()
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.login("<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.logout()
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.login("<username>", "<password>")
torrents = client.get_recommended(type=SearchParamType.HD_HUN)
for torrent in torrents:
print(torrent['title'], torrent['type'], torrent['size'], torrent['id'])
client.logout()
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
ncoreparser-1.9.1.tar.gz
(15.1 kB
view details)
Built Distribution
File details
Details for the file ncoreparser-1.9.1.tar.gz
.
File metadata
- Download URL: ncoreparser-1.9.1.tar.gz
- Upload date:
- Size: 15.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 877fb4ad0b90e33934a7d5c1e9820c43d71984397b9c4e72e56e79d047ee5d68 |
|
MD5 | 89009f0987e04b57cdd7b186a765fcd5 |
|
BLAKE2b-256 | 1196cec62625aaf9f1b9c4523aebf31dd4940e91c80d08ff9db9d1bd8bfba929 |
File details
Details for the file ncoreparser-1.9.1-py2.py3-none-any.whl
.
File metadata
- Download URL: ncoreparser-1.9.1-py2.py3-none-any.whl
- Upload date:
- Size: 9.6 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 478aa93a6b1a2e1786ddbe55832b608239634cdc319861bfb9405d26ddcd2d59 |
|
MD5 | 7b997babbf1e2f1dc08202095cf3bf1c |
|
BLAKE2b-256 | 9ab35bf462b530bfa8499ce5cc5ec15f3a703f2208d2846e5074072be280adee |