---
id: huntorrent
name: HunTorrent
description: "HunTorrent is a HUNGARIAN Semi-Private Torrent Tracker for MOVIES / TV / GENERAL"
language: hu-HU
type: semi-private
encoding: UTF-8
requestDelay: 2
links:
  - https://huntorrent.org/
legacylinks:
  - https://huntorrent.net/

caps:
  categorymappings:
    - {id: 28, cat: Movies/SD, desc: "Cam/Külföldi", default: true}
    - {id: 27, cat: Movies/SD, desc: "Cam/Magyar", default: true}
    - {id: 4, cat: Movies/DVD, desc: "DVDR/Külföldi", default: true}
    - {id: 3, cat: Movies/DVD, desc: "DVDR/Magyar", default: true}
    - {id: 6, cat: Movies/HD, desc: "HD/Külföldi", default: true}
    - {id: 5, cat: Movies/HD, desc: "HD/Magyar", default: true}
    - {id: 2, cat: Movies/SD, desc: "XviD/Külföldi", default: true}
    - {id: 1, cat: Movies/SD, desc: "XviD/Magyar", default: true}
    - {id: 17, cat: PC/Games, desc: "Játék/ISO", default: true}
    - {id: 18, cat: PC/Games, desc: "Játék/RIP", default: true}
    - {id: 19, cat: Console, desc: "Konzol", default: true}
    - {id: 25, cat: Other, desc: "Kép", default: true}
    - {id: 24, cat: Books, desc: "eBook/Külföldi", default: true}
    - {id: 23, cat: Books, desc: "eBook/Magyar", default: true}
    - {id: 38, cat: Audio/Audiobook, desc: "Hangoskönyv", default: true}
    - {id: 26, cat: PC/Mobile-Other, desc: "Mobil", default: true}
    - {id: 20, cat: PC/ISO, desc: "Program/ISO", default: true}
    - {id: 21, cat: PC/0day, desc: "Program/RIP", default: true}
    - {id: 31, cat: TV/HD, desc: "Sorozat/HD/Külföldi", default: true}
    - {id: 9, cat: TV/HD, desc: "Sorozat/HD/Magyar", default: true}
    - {id: 8, cat: TV/SD, desc: "Sorozat/Külföldi", default: true}
    - {id: 7, cat: TV/SD, desc: "Sorozat/Magyar", default: true}
    - {id: 13, cat: Audio/Video, desc: "Klip/Külföldi", default: true}
    - {id: 12, cat: Audio/Video, desc: "Klip/Külföldi", default: true}
    - {id: 11, cat: Audio/MP3, desc: "MP3/Külföldi", default: true}
    - {id: 10, cat: Audio/MP3, desc: "MP3/Magyar", default: true}
    - {id: 16, cat: XXX/DVD, desc: "XXX/DVD", default: false}
    - {id: 32, cat: XXX/x264, desc: "XXX/HD", default: false}
    - {id: 14, cat: XXX/ImageSet, desc: "XXX/Kép", default: false}
    - {id: 15, cat: XXX/SD, desc: "XXX/XVID", default: false}

  modes:
    search: [q]
    tv-search: [q, season, ep, imdbid]
    movie-search: [q, imdbid]
    music-search: [q]
    book-search: [q]

settings:
  - name: info_about
    type: info
    label: About this HunTorrent indexer
    default: This indexer does not include the <b>bithorlo</b> torrent pages. Use the HunTorrent-bithorlo indexer to access those.
  - name: cookie
    type: text
    label: Cookie
  - name: info_cookie
    type: info_cookie
  - name: useragent
    type: text
    label: User-Agent
  - name: info_useragent
    type: info_useragent
  - name: sort
    type: select
    label: Sort requested from site
    default: 4
    options:
      4: created
      7: seeders
      5: size
      1: title
  - name: type
    type: select
    label: Order requested from site
    default: desc
    options:
      desc: desc
      asc: asc
  - name: info_tpp
    type: info
    label: Results Per Page
    default: For best results, change the <b>Torrents per page:</b> setting to <b>100</b> on your account profile.

login:
  method: cookie
  # using cookie method because login page has embedded Google reCAPTCHA
  inputs:
    cookie: "{{ .Config.cookie }}"
  test:
    path: browse.php
    selector: a[href^="logout.php?k="]

search:
  headers:
    User-Agent: ["{{ .Config.useragent }}"]
  paths:
    # https://huntorrent.net/browse.php?&korhatar=0&incldead=1&xyz=yes&c28=1&c27=1&c6=1&c5=1&sort=4&type=desc
    - path: browse.php
      categories: [28, 27, 4, 3, 6, 5, 2, 1, 17, 18, 19, 25, 24, 23, 38, 26, 20, 21, 31, 9, 8, 7, 13, 12, 11, 10]
      inputs:
        search: "{{ if .Query.IMDBID }}{{ .Query.IMDBID }}{{ else }}{{ .Keywords }}{{ end }}"
    - path: browse.php
      categories: [16, 32, 14, 15]
      inputs:
        viewMode: xxx
        search: "{{ .Keywords }}"
  inputs:
    $raw: "{{ range .Categories }}c{{.}}=1&{{end}}"
    xyz: yes
    # Age Limit: 0 all, 1 no, 5 6, 2 12, 3 16, 4 18
    korhatar: 0
    # 0 active, 1 active+dead, 2 dead, 3 my uploads, 4  waiting for seed, 7 my bookmarks, 12 reseeded by me
    incldead: 1
    sort: "{{ .Config.sort }}"
    type: "{{ .Config.type }}"

  rows:
    selector: table.torrent-table > tbody > tr[id^="torrent-main-"]

  fields:
    category:
      selector: a[href^="browse.php?cat="]
      attribute: href
      filters:
        - name: querystring
          args: cat
    title:
      selector: a.torrent-title-link
    details:
      selector: a.torrent-title-link
      attribute: href
      filters:
        - name: replace
          args: ["&hit=1", ""]
    download:
      selector: a[href^="download.php?"]
      attribute: href
    genre:
      selector: a[data-mufaj]
      attribute: data-mufaj
    description:
      selector: div.torrent-subtitle
      filters:
        - name: append
          args: "{{ if .Result.genre }}</br>{{ .Result.genre }}{{ else }}{{ end }}"
    imdbid:
      selector: a[href*="imdb.com/title/tt"]
      attribute: href
    poster:
      selector: a[data-poster]
      attribute: data-poster
    date:
      selector: a[data-added]
      attribute: data-added
      filters:
        - name: append
          args: " +01:00" # CET
        - name: dateparse
          args: "yyyy-MM-dd HH:mm zzz"
    size:
      selector: a[data-size]
      attribute: data-size
    grabs:
      selector: td:nth-last-child(3)
    seeders:
      selector: td:nth-last-child(2)
    leechers:
      selector: td:nth-last-child(1)
    downloadvolumefactor:
      text: 1
    uploadvolumefactor:
      text: 2
    minimumratio:
      text: 1.0
    minimumseedtime:
      # 32 hours (as seconds = 32 x 60 x 60)
      text: 115200
# engine n/a
