From 51223f6dc13c4bec905b35594e4efd1e7c43f189 Mon Sep 17 00:00:00 2001 From: Berkecan <40901692+Berkecann@users.noreply.github.com> Date: Sun, 13 Sep 2026 05:56:18 +0300 Subject: [PATCH] Add ManifestDeX manifest provider --- opensteamtool.example.toml | 1 + src/Utils/SteamMetadata/ManifestClient.cpp | 10 +++++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/opensteamtool.example.toml b/opensteamtool.example.toml index 574a8f75..532f2799 100644 --- a/opensteamtool.example.toml +++ b/opensteamtool.example.toml @@ -10,6 +10,7 @@ level = "debug" [manifest] # Which upstream API to query for depot manifest request codes. # "opensteamtool" → https://manifest.opensteamtool.com/{gid} (default) +# "manifestdex" → https://manifest.manifestdex.com/{gid} # "wudrm" → http://gmrc.wudrm.com/manifest/{gid} (recommended for China users) # "steamrun" → https://manifest.steam.run/api/manifest/{gid} # If /config/lua/manifest.lua defines fetch_manifest_code(gid) or diff --git a/src/Utils/SteamMetadata/ManifestClient.cpp b/src/Utils/SteamMetadata/ManifestClient.cpp index 7cef98bc..5a775b80 100644 --- a/src/Utils/SteamMetadata/ManifestClient.cpp +++ b/src/Utils/SteamMetadata/ManifestClient.cpp @@ -42,14 +42,18 @@ namespace ManifestClient { std::string_view name; // matches [manifest] url = "..." const char* urlTemplate; // full literal with one %llu — for log & path Parser parse; + const wchar_t* headers; }; - consteval Provider Make(std::string_view name, const char* url, Parser parse) { - return {name, url, parse}; + consteval Provider Make(std::string_view name, const char* url, Parser parse, + const wchar_t* headers = nullptr) { + return {name, url, parse, headers}; } static constexpr Provider kProviders[] = { Make("opensteamtool", "https://manifest.opensteamtool.com/%llu", ParsePlainUint), + Make("manifestdex", "https://manifest.manifestdex.com/%llu", ParsePlainUint, + L"User-Agent: ManifestDeX/1.0\r\n"), Make("wudrm", "http://gmrc.wudrm.com/manifest/%llu", ParsePlainUint), Make("steamrun", "https://manifest.steam.run/api/manifest/%llu", ParseSteamRunJson), }; @@ -92,7 +96,7 @@ namespace ManifestClient { urlLog, nullptr, 0, - nullptr, + p.headers, timeouts.resolve, timeouts.connect, timeouts.send,