Lidarr/Readarr, integration inspector, app versions, grouped alerts

Lidarr and Readarr join the shared *arr reader. Integrations get an Inspect button that
runs the reader once and shows what each request returned as shapes (never values) and
where the result is empty. Operations -> App versions compares each application's version
with its newest GitHub release (lookup off until an admin switches it on; optional alert).
The Alerts page can group by source, kind of problem or type of alert. The shared HTTP
helper no longer reuses connections (stale-socket resets). Migration 0078; docs and tests
included.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
bobbanandClaude Sonnet 5.5 committed 2026-10-29 20:07:36 +01:00
1 parent 551eb1597a
commit 93aaf5476d
45 files changed
+10033 -65

No files matched your search

+39 -2
View File
@@ -1463,7 +1463,7 @@ export interface FragnetAccount {
/** One Sonarr, Radarr or Prowlarr (an integration of that type), as the media page shows it. */
export interface ArrApp {
id: number;
kind: "sonarr" | "radarr" | "prowlarr";
kind: "sonarr" | "radarr" | "prowlarr" | "lidarr" | "readarr";
name: string;
enabled: boolean;
url: string;
@@ -1528,6 +1528,37 @@ export interface GrafanaInstance {
problems: { key: string; message: string; severity: "warning" | "critical" }[];
}
/** What running an integration's reader once showed: each request it made (and the shape of the answer, never its values), what it made of them, and where that is empty. */
export interface IntegrationInspection {
type: IntegrationType;
name: string;
ok: boolean;
error: string | null;
ms: number;
calls: { method: string; path: string; status: number; ms: number; bytes: number; shape: string | null; error?: string }[];
resultShape: string | null;
empty: { path: string; what: "null" | "text" | "list" | "every-item" }[];
}
/** What each connected application runs, against the newest release kept for it. */
export interface AppVersions {
enabled: boolean;
alertAfterDays: number;
lastCheckedAt: string | null;
rows: {
integrationId: number;
type: string;
label: string;
name: string;
running: string;
latest: { tag: string; publishedAt: string | null; url: string | null } | null;
lookupError: string | null;
lag: "same" | "patch" | "minor" | "major" | "ahead" | "unknown";
daysOut: number | null;
checkedAt: string | null;
}[];
}
export type FragnetSignal = "start" | "stop" | "restart" | "kill";
export interface CostItem {
@@ -2663,7 +2694,7 @@ export interface ManualTaskInput {
enabled?: boolean;
}
export type IntegrationType = "proxmox" | "synology" | "semaphore" | "tailscale" | "gitea" | "dockhand" | "uptimekuma" | "phpipam" | "pbs" | "osticket" | "unifi" | "npm" | "homeassistant" | "ups" | "jellyfin" | "authentik" | "prometheus" | "immich" | "paperless" | "nextcloud" | "netbox" | "n8n" | "hetzner" | "speedtest" | "fragnet" | "sonarr" | "radarr" | "prowlarr" | "adguard" | "grafana";
export type IntegrationType = "proxmox" | "synology" | "semaphore" | "tailscale" | "gitea" | "dockhand" | "uptimekuma" | "phpipam" | "pbs" | "osticket" | "unifi" | "npm" | "homeassistant" | "ups" | "jellyfin" | "authentik" | "prometheus" | "immich" | "paperless" | "nextcloud" | "netbox" | "n8n" | "hetzner" | "speedtest" | "fragnet" | "sonarr" | "radarr" | "prowlarr" | "adguard" | "grafana" | "lidarr" | "readarr";
export interface IntegrationField {
key: string;
@@ -3265,6 +3296,11 @@ export const api = {
list: () => request<{ speedtests: SpeedtestInfo[] }>("/api/speedtest"),
history: (id: number, days: number) => request<SpeedtestHistory>(`/api/speedtest/${id}/history?days=${days}`),
},
versions: {
get: () => request<AppVersions>("/api/versions"),
save: (data: { enabled: boolean; alertAfterDays: number }) => request<AppVersions>("/api/versions/settings", { method: "PUT", body: JSON.stringify(data) }),
refresh: () => request<AppVersions & { result: { checked: number; failed: number } }>("/api/versions/refresh", { method: "POST" }),
},
adguard: {
list: () => request<{ instances: AdguardInstance[] }>("/api/adguard"),
},
@@ -3843,6 +3879,7 @@ export const api = {
integration: { id: number; type: IntegrationType; name: string; enabled: boolean };
config: Record<string, string | boolean>;
}>(`/api/integrations/${id}/config`),
inspect: (id: number) => request<IntegrationInspection>(`/api/integrations/${id}/inspect`, { method: "POST" }),
testExisting: (id: number, config: Record<string, string | boolean>) =>
request<{ ok: boolean; latencyMs?: number; error?: string }>(`/api/integrations/${id}/test`, {
method: "POST",