/** * Kubernetes Type Definitions * * Provides type-safe interfaces for Kubernetes API clients and operations */ import * as k8s from '@kubernetes/client-node'; /** * Union type of all standard K8s API clients */ export type StandardK8sApiClient = k8s.CoreV1Api | k8s.AppsV1Api | k8s.BatchV1Api | k8s.NetworkingV1Api | k8s.RbacAuthorizationV1Api | k8s.AutoscalingV2Api | k8s.AuthorizationV1Api; /** * Type-safe resource configuration for K8s API operations * Uses string for method names to avoid union type constraints */ export interface ResourceConfig { api: StandardK8sApiClient; createMethod: string; patchMethod: string; deleteMethod: string; readMethod: string; namespaced: boolean; } /** * Safely access a method on a K8s API client * This is needed because TypeScript doesn't allow string indexing on union types */ export declare function getApiMethod(api: StandardK8sApiClient, methodName: string): unknown; /** * Get typed API client for a specific K8s resource kind * * @param kc - Kubernetes config * @param kind - Resource kind (e.g., 'Deployment', 'Service') * @returns Resource configuration with typed API client */ export declare function getResourceConfig(kc: k8s.KubeConfig, kind: string): ResourceConfig | undefined; //# sourceMappingURL=types.d.ts.map