Files
pulse/frontend-modern/src/api/monitoredSystemLedger.ts
T
2026-03-18 16:06:30 +00:00

24 lines
651 B
TypeScript

import { apiFetchJSON } from '@/utils/apiClient';
export interface MonitoredSystemLedgerEntry {
name: string;
type: string;
status: string; // "online" | "offline" | "unknown"
last_seen: string; // RFC3339 or empty
source: string;
}
export interface MonitoredSystemLedgerResponse {
systems: MonitoredSystemLedgerEntry[];
total: number;
limit: number; // 0 = unlimited
}
export class MonitoredSystemLedgerAPI {
private static readonly baseUrl = '/api/license/monitored-system-ledger';
static async getLedger(): Promise<MonitoredSystemLedgerResponse> {
return apiFetchJSON<MonitoredSystemLedgerResponse>(this.baseUrl);
}
}