|
@@ -2,8 +2,6 @@
|
|
// emby: `{url}/emby/{endpoint}?api_key={key}`,
|
|
// emby: `{url}/emby/{endpoint}?api_key={key}`,
|
|
// jellyfin: `{url}/emby/{endpoint}?api_key={key}`,
|
|
// jellyfin: `{url}/emby/{endpoint}?api_key={key}`,
|
|
// pihole: `{url}/admin/{endpoint}`,
|
|
// pihole: `{url}/admin/{endpoint}`,
|
|
-// radarr: `{url}/api/v3/{endpoint}?apikey={key}`,
|
|
|
|
-// sonarr: `{url}/api/v3/{endpoint}?apikey={key}`,
|
|
|
|
// speedtest: `{url}/api/{endpoint}`,
|
|
// speedtest: `{url}/api/{endpoint}`,
|
|
// tautulli: `{url}/api/v2?apikey={key}&cmd={endpoint}`,
|
|
// tautulli: `{url}/api/v2?apikey={key}&cmd={endpoint}`,
|
|
// traefik: `{url}/api/{endpoint}`,
|
|
// traefik: `{url}/api/{endpoint}`,
|
|
@@ -12,18 +10,14 @@
|
|
// transmission: `{url}/transmission/rpc`,
|
|
// transmission: `{url}/transmission/rpc`,
|
|
// qbittorrent: `{url}/api/v2/{endpoint}`,
|
|
// qbittorrent: `{url}/api/v2/{endpoint}`,
|
|
// jellyseerr: `{url}/api/v1/{endpoint}`,
|
|
// jellyseerr: `{url}/api/v1/{endpoint}`,
|
|
-// overseerr: `{url}/api/v1/{endpoint}`,
|
|
|
|
// ombi: `{url}/api/v1/{endpoint}`,
|
|
// ombi: `{url}/api/v1/{endpoint}`,
|
|
// npm: `{url}/api/{endpoint}`,
|
|
// npm: `{url}/api/{endpoint}`,
|
|
// lidarr: `{url}/api/v1/{endpoint}?apikey={key}`,
|
|
// lidarr: `{url}/api/v1/{endpoint}?apikey={key}`,
|
|
// readarr: `{url}/api/v1/{endpoint}?apikey={key}`,
|
|
// readarr: `{url}/api/v1/{endpoint}?apikey={key}`,
|
|
-// bazarr: `{url}/api/{endpoint}/wanted?apikey={key}`,
|
|
|
|
// sabnzbd: `{url}/api/?apikey={key}&output=json&mode={endpoint}`,
|
|
// sabnzbd: `{url}/api/?apikey={key}&output=json&mode={endpoint}`,
|
|
-// coinmarketcap: `https://pro-api.coinmarketcap.com/{endpoint}`,
|
|
|
|
// gotify: `{url}/{endpoint}`,
|
|
// gotify: `{url}/{endpoint}`,
|
|
// prowlarr: `{url}/api/v1/{endpoint}`,
|
|
// prowlarr: `{url}/api/v1/{endpoint}`,
|
|
// jackett: `{url}/api/v2.0/{endpoint}?apikey={key}&configured=true`,
|
|
// jackett: `{url}/api/v2.0/{endpoint}?apikey={key}&configured=true`,
|
|
-// adguard: `{url}/control/{endpoint}`,
|
|
|
|
// strelaysrv: `{url}/{endpoint}`,
|
|
// strelaysrv: `{url}/{endpoint}`,
|
|
// mastodon: `{url}/api/v1/{endpoint}`,
|
|
// mastodon: `{url}/api/v1/{endpoint}`,
|
|
// };
|
|
// };
|
|
@@ -38,13 +32,16 @@ export function formatApiCall(url, args) {
|
|
return url.replace(find, replace);
|
|
return url.replace(find, replace);
|
|
}
|
|
}
|
|
|
|
|
|
-export function formatProxyUrl(widget, endpoint) {
|
|
|
|
|
|
+export function formatProxyUrl(widget, endpoint, endpointParams) {
|
|
const params = new URLSearchParams({
|
|
const params = new URLSearchParams({
|
|
type: widget.type,
|
|
type: widget.type,
|
|
group: widget.service_group,
|
|
group: widget.service_group,
|
|
service: widget.service_name,
|
|
service: widget.service_name,
|
|
endpoint,
|
|
endpoint,
|
|
});
|
|
});
|
|
|
|
+ if (endpointParams) {
|
|
|
|
+ params.append("params", JSON.stringify(endpointParams));
|
|
|
|
+ }
|
|
return `/api/services/proxy?${params.toString()}`;
|
|
return `/api/services/proxy?${params.toString()}`;
|
|
}
|
|
}
|
|
|
|
|