Feat/Rede torrents (#34)

* new: feat: add brand new redetorrent.com indexer

* chg: refactor: create common package

* chg: fix: comandohds formatting

* chg: fix: dual audio detection

* chg: fix: parsing issues

* chg: refactor: remove duplicated code

* chg: refactor: move test funcs to common file
This commit is contained in:
2025-07-22 14:57:05 -03:00
committed by GitHub
parent 0b21e3b1e7
commit 782f9d6b3f
13 changed files with 762 additions and 327 deletions

View File

@@ -22,6 +22,8 @@ type Indexer struct {
type IndexerMeta struct {
URL string
SearchURL string
// pattern for pagination, e.g. "page/%s"
PagePattern string
}
type Response struct {
@@ -99,6 +101,17 @@ func HandlerIndex(w http.ResponseWriter, r *http.Request) {
},
},
},
"/indexers/rede_torrent": []map[string]interface{}{
{
"method": "GET",
"description": "Indexer for rede torrent",
"query_params": map[string]string{
"q": "search query",
"page": "page number",
"filter_results": "if results with similarity equals to zero should be filtered (true/false)",
},
},
},
"/indexers/manual": []map[string]interface{}{
{
"method": "POST",
@@ -120,6 +133,12 @@ func HandlerIndex(w http.ResponseWriter, r *http.Request) {
},
},
},
"/ui/": []map[string]interface{}{
{
"method": "GET",
"description": "Show the unified search UI (only work if Meilisearch is enabled)",
},
},
},
})
if err != nil {