Unofficial Python API for ThePirateBay.
$ pip install ThePirateBay
If you love and use TPB, please consider donating via gittip. Any support is appreciated!
The class that parses the torrent listing page, and builds up all Torrent objects.
get_recent_torrents()
- Returns a list of Torrent objects from the 'recent' page of TPB
search(query, category=0)
- Searches TPB for the passed query and returns a list of Torrents
Represents one single torrent on TPB
print_torrent()
- Print the details of a torrent
- title # the title of the torrent
- url # TPB url for the torrent
- category # the main category
- sub_category # the sub category
- magnet_link # magnet download link
- torrent_link # .torrent download link
- created # uploaded date time
- size # size of torrent
- user # username of uploader
- seeders # number of seeders
- leechers # number of leechers
If you want to add any new features, or improve existing ones, feel free to send a pull request!