Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upHow can I get total number of downloads in a swarm. #1627
Closed
Labels
Comments
This comment has been minimized.
This comment has been minimized.
|
Hi @i-coderdev To get this information you can use the following example code: torrent.discovery.tracker.on('scrape', function (data) {
console.log('got a scrape response from tracker: ' + data.announce)
console.log('number of seeders in the swarm: ' + data.complete)
console.log('number of leechers in the swarm: ' + data.incomplete)
console.log('number of total downloads of this torrent: ' + data.downloaded)
})
torrent.discovery.tracker.scrape()
This will invoke the scrape function within bittorrent-tracker's client and return all metadata from the tracker. Alternatively you can use bittorrent-tracker standalone without having the overhead of the webtorrent library. As this is a question, I'm going to close this issue but if you need any more help with this, feel free to continue the conversation in this ticket. Kind regards |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is not a issues,
Anyone can tell me how can I get total number of downloads information from torrent infoHashes.