Archived
feat: gate session cleanup by runtime capabilities
This commit is contained in:
@@ -1,6 +1,12 @@
|
||||
export type MachineKind = "local" | "remote";
|
||||
export type MachineStatus = "unknown" | "online" | "offline" | "error";
|
||||
|
||||
export const PI_WEB_CAPABILITIES = {
|
||||
sessionsDeleteArchived: "sessions.deleteArchived",
|
||||
} as const;
|
||||
|
||||
export type PiWebCapability = typeof PI_WEB_CAPABILITIES[keyof typeof PI_WEB_CAPABILITIES];
|
||||
|
||||
export interface Machine {
|
||||
id: string;
|
||||
name: string;
|
||||
@@ -22,6 +28,17 @@ export interface MachineHealth {
|
||||
error?: string;
|
||||
}
|
||||
|
||||
export interface MachineRuntime {
|
||||
machineId: string;
|
||||
ok: boolean;
|
||||
checkedAt: string;
|
||||
packageName?: string;
|
||||
generatedAt?: string;
|
||||
components?: PiWebRuntimeResponse["components"];
|
||||
capabilities?: PiWebCapability[];
|
||||
error?: string;
|
||||
}
|
||||
|
||||
export type PiWebShortcutConfig = Record<string, string | null>;
|
||||
export type PiWebPluginSettings = Record<string, unknown>;
|
||||
export type PiWebPluginConfigMap = Record<string, PiWebPluginConfig>;
|
||||
@@ -337,6 +354,15 @@ export interface PiWebComponentStatus {
|
||||
error?: string;
|
||||
}
|
||||
|
||||
export interface PiWebRuntimeComponent {
|
||||
component: PiWebServiceComponent;
|
||||
label: string;
|
||||
runtimeVersion?: string;
|
||||
available: boolean;
|
||||
capabilities: PiWebCapability[];
|
||||
error?: string;
|
||||
}
|
||||
|
||||
export interface PiWebReleaseStatus {
|
||||
packageName: string;
|
||||
latestVersion?: string;
|
||||
@@ -363,6 +389,16 @@ export interface PiWebVersionResponse {
|
||||
};
|
||||
}
|
||||
|
||||
export interface PiWebRuntimeResponse {
|
||||
packageName: string;
|
||||
generatedAt: string;
|
||||
components: {
|
||||
web: PiWebRuntimeComponent;
|
||||
sessiond: PiWebRuntimeComponent;
|
||||
};
|
||||
capabilities: PiWebCapability[];
|
||||
}
|
||||
|
||||
export interface PiWebStatusResponse extends PiWebVersionResponse {
|
||||
release: PiWebReleaseStatus;
|
||||
commands: {
|
||||
|
||||
Reference in New Issue
Block a user