2017 © Pedro Peláez
 

library torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

image

sergey-s-moiseev/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  • Friday, June 22, 2018
  • by sergey-s-moiseev
  • Repository
  • 2 Watchers
  • 0 Stars
  • 169 Installations
  • HTML
  • 0 Dependents
  • 0 Suggesters
  • 7 Forks
  • 0 Open issues
  • 10 Versions
  • 2 % Grown

The README.md

Torrent Scraper

About

This library provides an abstraction to search for torrent files accross some torrent websites., (*1)

Usage

<?php

$scraperService = new \SergeySMoiseev\TorrentScraper\TorrentScraperService([
    \SergeySMoiseev\TorrentScraper\Adapter\EzTvAdapter::ADAPTER_NAME,
    \SergeySMoiseev\TorrentScraper\Adapter\KickassTorrentsAdapter::ADAPTER_NAME
]);
$results = $scraperService->search('query');

foreach ($results as $result) {
    $result->getName();
    $result->getSource();
    $result->getSeeders();
    $result->getLeechers();
    $result->getTorrentUrl();
    $result->getMagnetUrl();
    $result->getDetailsUrl();
    $result->getCategory();
    $result->getSize();
}

Additional torrents info

For scrap Seeds and Peers by Announce trackers use python daemon in /daemon folder, (*2)

Daemon usage

python daemon/main.py 

Server was started on 0.0.0.0:5000 (by default) for get additional information you need to send post JSON request [Content-Type:application/json] on server, (*3)

{"data":
  {
    "trackers": ["udp://tracker1.wasabii.com.tw:6969/announce","…"],
    "hashes": ["89925fb48cae260801f35fb7175530bf6e5e055a", "…"]
  },
  "callback": "http://yousite.url/callback_action",
  "private_key": "your_ip_key" 

}

Where: - trackers - list of announce servers - hashes - torrent hashes - callback - url to you callback action for result JSON ('http://' or 'https://" is important!) - private_key - self generated key for protect your action (recommendation:make new key for each request) ``, (*4)

Result JSON format:, (*5)

{"data":
    [
      {"89925fb48cae260801f35fb7175530bf6e5e055a": {"peers": 1234, "seeds": 4321},
      "…"
    ]
}
<?php

$scraperService = new \SergeySMoiseev\TorrentScraper\TorrentScraperService();
$query = [
    "trackers": ["udp://tracker1.wasabii.com.tw:6969/announce","…"],
    "hashes": ["89925fb48cae260801f35fb7175530bf6e5e055a", "…"]
];
$results = $scraperService->scrap($query, "http://yousite.url/callback_action", "your_ip_key");

Result will come on callback URL after collect information from announce trackers, (*6)

Check Daemon is running

<?php

$scraperService = new \SergeySMoiseev\TorrentScraper\TorrentScraperService();
$results = $scraperService->ping();

Available adapters

The Versions

14/10 2016

v1.0.4

1.0.4.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

14/10 2016

v1.0.1

1.0.1.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

14/10 2016

v1.0.3

1.0.3.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

27/03 2016

v1.0.0

1.0.0.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

27/03 2016

v1.0.2

1.0.2.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

28/02 2016

v0.1.4

0.1.4.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

02/08 2015

v0.1.3

0.1.3.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

01/02 2015

v0.1.2

0.1.2.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay

01/02 2015

v0.1.1

0.1.1.0 https://github.com/xurumelous/torrent-scraper

Provide an abstraction to seach for torrent files on many websites.

  Sources   Download

MIT

The Requires

 

The Development Requires

torrent kickass piratebay