#pragma once
#include <nlohmann/json_fwd.hpp>
#include "torlinkc/sources/types.hpp"
namespace torlinkc {
// BitTorrented, a general video index. Feeds Movies and TV (the API can't
// tell anime from any other video, and Games stays FitGirl's alone). Ported
// from sources/bittorrented.ts.
Source bittorrentedSource();
// Exposed for testing: maps the API's raw result rows to TorrentResult, pure
// and without a live request. Rows without a valid 40-char hex info hash are
// dropped.
std::vector<TorrentResult> mapBittorrentedResults(const nlohmann::json& results, const std::string& sourceId);
} // namespace torlinkc