-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Welcome to the torrentlib wiki!
Python helpers for BitTorrent tracker queries, peer communication, and metadata inspection.
torrentlib is not a full BitTorrent client. It can:
- load
.torrentmetadata - announce to HTTP and UDP trackers
- collect IPv4 and IPv6 peer lists
- connect to peers that support the extension protocol
- download torrent metadata from peers via
ut_metadata - process peer exchange (
ut_pex) messages
It does not manage piece downloads/uploads for complete content transfer.
To begin using the library, start by creating a Torrent object and then querying trackers for living peers. If you instantiate the Torrent object using an info hash or a magnet link, you will also need to contact a peer to download the metadata.
Beyond the core torrent lifecycle, the library provides built-in interfaces to check tracker health and to modify, retrieve information from, or rebuild .torrent files. For implementation details and troubleshooting, you can explore the error handling guide and comprehensive usage examples.