media-server-docker-compose/config/prowlarr/Definitions/xthor-api.yml

207 lines
7.0 KiB
YAML
Raw Normal View History

2024-04-07 00:37:31 -04:00
---
id: xthor-api
name: Xthor (API)
description: "General French Private Tracker"
language: fr-FR
type: private
encoding: windows-1252
requestDelay: 2.5
links:
- https://xthor.tk/
legacylinks:
- https://xthor.bz/
- https://xthor.to/
- https://xthor.tk
caps:
categorymappings:
# Movies / Films
- {id: 118, cat: Movies/BluRay, desc: "Films/2160p/Bluray"}
- {id: 119, cat: Movies/UHD, desc: "Films/2160p/Remux"}
- {id: 107, cat: Movies/UHD, desc: "Films/2160p/x265"}
- {id: 1, cat: Movies/BluRay, desc: "Films/1080p/BluRay"}
- {id: 2, cat: Movies/HD, desc: "Films/1080p/Remux"}
- {id: 100, cat: Movies/HD, desc: "Films/1080p/x265"}
- {id: 4, cat: Movies/HD, desc: "Films/1080p/x264"}
- {id: 5, cat: Movies/HD, desc: "Films/720p/x264"}
- {id: 7, cat: Movies/SD, desc: "Films/SD/x264"}
- {id: 3, cat: Movies/3D, desc: "Films/3D"}
- {id: 6, cat: Movies/SD, desc: "Films/XviD"}
- {id: 8, cat: Movies/DVD, desc: "Films/DVD"}
- {id: 122, cat: Movies/HD, desc: "Films/HDTV"}
- {id: 94, cat: Movies/WEB-DL, desc: "Films/WEBDL"}
- {id: 95, cat: Movies/WEB-DL, desc: "Films/WEBRiP"}
- {id: 12, cat: TV/Documentary, desc: "Films/Documentaire"}
- {id: 31, cat: Movies/Other, desc: "Films/Animation"}
- {id: 33, cat: Movies/Other, desc: "Films/Spectacle"}
- {id: 125, cat: TV/Sport, desc: "Films/Sports"}
- {id: 20, cat: Audio/Video, desc: "Films/Concerts, Clips"}
- {id: 9, cat: Movies/Other, desc: "Films/VOSTFR"}
# TV Series / Series TV
- {id: 104, cat: TV/Other, desc: "Series/BluRay"}
- {id: 13, cat: TV, desc: "Series/Pack VF"}
- {id: 15, cat: TV/HD, desc: "Series/HD VF"}
- {id: 14, cat: TV/SD, desc: "Series/SD VF"}
- {id: 98, cat: TV/Other, desc: "Series/Pack VOSTFR"}
- {id: 17, cat: TV/HD, desc: "Series/HD VOSTFR"}
- {id: 16, cat: TV/SD, desc: "Series/SD VOSTFR"}
- {id: 101, cat: TV/Anime, desc: "Series/Packs Anime"}
- {id: 32, cat: TV/Anime, desc: "Series/Animes"}
- {id: 110, cat: TV/Anime, desc: "Series/Anime VOSTFR"}
- {id: 123, cat: TV/Other, desc: "Series/Animation"}
- {id: 109, cat: TV/Documentary, desc: "Series/DOC"}
- {id: 34, cat: TV/Sport, desc: "Series/Sport"}
- {id: 30, cat: TV/Other, desc: "Series/Emission TV"}
# Porn / XxX
- {id: 36, cat: XXX, desc: "MISC/XxX/Films"}
- {id: 105, cat: XXX, desc: "MISC/XxX/Séries"}
- {id: 114, cat: XXX, desc: "MISC/XxX/Lesbiennes"}
- {id: 115, cat: XXX, desc: "MISC/XxX/Gays"}
- {id: 113, cat: XXX, desc: "MISC/XxX/Hentai"}
- {id: 120, cat: XXX, desc: "MISC/XxX/Magazines"}
# Books / Livres
- {id: 24, cat: Books/EBook, desc: "Livres/Romans"}
- {id: 124, cat: Audio/Audiobook, desc: "Livres/Audio Books"}
- {id: 96, cat: Books/Mags, desc: "Livres/Magazines"}
- {id: 99, cat: Books/Other, desc: "Livres/Bandes dessinées"}
- {id: 116, cat: Books/EBook, desc: "Livres/Romans Jeunesse"}
- {id: 102, cat: Books/Comics, desc: "Livres/Comics"}
- {id: 103, cat: Books/Other, desc: "Livres/Mangas"}
# Softwares / Logiciels
- {id: 25, cat: PC/Games, desc: "Logiciels/Jeux PC"}
- {id: 27, cat: Console/PS3, desc: "Logiciels/Playstation"}
- {id: 111, cat: PC/Mac, desc: "Logiciels/Jeux MAC"}
- {id: 26, cat: Console/XBox 360, desc: "Logiciels/XboX"}
- {id: 112, cat: PC, desc: "Logiciels/Jeux Linux"}
- {id: 28, cat: Console/Wii, desc: "Logiciels/Nintendo"}
- {id: 29, cat: Console/NDS, desc: "Logiciels/NDS"}
- {id: 117, cat: PC, desc: "Logiciels/ROM"}
- {id: 21, cat: PC, desc: "Logiciels/Applis PC"}
- {id: 22, cat: PC/Mac, desc: "Logiciels/Applis Mac"}
- {id: 23, cat: PC/Mobile-Android, desc: "Logiciels/Smartphone"}
modes:
search: [q]
movie-search: [q, tmdbid]
tv-search: [q, season, ep, tmdbid]
book-search: [q]
settings:
- name: passkey
type: text
label: Passkey
- name: info_key
type: info
label: About your Passkey
default: "Find your Passkey on <a href=\"https://xthor.tk/api_doc.php\" target =_blank>Xthor > API page</a>."
- name: freeleech
type: checkbox
label: Search freeleech only
default: false
- name: multilang
type: checkbox
label: Replace MULTi by another language in release name
default: false
- name: multilanguage
type: select
label: Replace MULTi by this language
default: FRENCH
options:
FRENCH: FRENCH
MULTi.FRENCH: MULTi.FRENCH
ENGLISH: ENGLISH
MULTi.ENGLISH: MULTi.ENGLISH
VOSTFR: VOSTFR
MULTi.VOSTFR: MULTi.VOSTFR
- name: vostfr
type: checkbox
label: Replace VOSTFR and SUBFRENCH with ENGLISH
default: false
login:
path: "https://api.xthor.tk/"
method: get
inputs:
passkey: "{{ .Config.passkey }}"
error:
- selector: ":root:contains(\"Passkey not found\")"
message:
text: "The Passkey was not accepted by {{ .Config.sitelink }}."
search:
paths:
# https://api.xthor.tk/?passkey=<redacted>&search=&category=&freeleech=&tmdbid=&size=&accent=&price=&page=
- path: "https://api.xthor.tk/"
inputs:
passkey: "{{ .Config.passkey }}"
category: "{{ if .Categories }}{{ range .Categories }}{{.}}+{{end}}{{ else }}{{ end }}"
search: "{{ .Keywords }}"
tmdbid: "{{ .Query.TMDBID }}"
freeleech: "{{ if .Config.freeleech }}1{{ else }}{{ end }}"
response:
type: json
noResultsMessage: '"descr": "no result"'
rows:
selector: torrents
fields:
_id:
selector: id
category:
selector: category
title_phase1:
selector: name
title_vostfr:
text: "{{ .Result.title_phase1 }}"
filters:
- name: re_replace
args: ["(?i)\\b(vostfr|subfrench)\\b", "ENGLISH"]
title_phase2:
text: "{{ if .Config.vostfr }}{{ .Result.title_vostfr }}{{ else }}{{ .Result.title_phase1 }}{{ end }}"
title_multilang:
text: "{{ .Result.title_phase2 }}"
filters:
- name: re_replace
args: ["(?i)\\b(MULTI(?!.*(?:FRENCH|ENGLISH|VOSTFR)))\\b", "{{ .Config.multilanguage }}"]
title:
text: "{{ if .Config.multilang }}{{ .Result.title_multilang }}{{ else }}{{ .Result.title_phase2 }}{{ end }}"
details:
text: "{{ .Config.sitelink }}details.php?id={{ .Result._id }}"
download:
selector: download_link
poster:
selector: descr
filters:
- name: regexp
args: ["({{ .Config.sitelink }}info_images\\/allocine\\/covers\\/film\\/small_\\d+?\\.jpg)"]
tmdbid:
selector: tmdb_id
files:
selector: numfiles
date:
selector: added
size:
selector: size
seeders:
selector: seeders
leechers:
selector: leechers
grabs:
selector: times_completed
downloadvolumefactor:
# api returns 0=false, 1=true
selector: freeleech
case:
0: 1 # not free
1: 0 # freeleech
uploadvolumefactor:
text: 1
minimumseedtime:
# 24 hours (as seconds = 1 x 24 x 60 x 60)
text: 86400
minimumratio:
# minimum ratio per torrent is 0.8
text: 0.8
# json api