import type { Skill, SearchOptions } from '../types/skill.js'; import { type ApiResponse, type ApiSearchResult, type ApiClientConfig, type RecommendationRequest, type TelemetryEvent, type RegistrySyncOptions, type PlatformStats } from './client.types.js'; export { ApiClientError, type ApiResponse, type ApiErrorResponse, type ApiSearchResult, type ApiClientConfig, type RecommendationRequest, type TelemetryEvent, type RegistrySyncOptions, type PlatformStats, } from './client.types.js'; import { ApiCache } from './cache.js'; import { type CallCacheOptions } from './client.cache.js'; export type { CallCacheOptions } from './client.cache.js'; export { generateAnonymousId } from './utils.js'; export { checkApiHealth } from './client.health.js'; export { ApiSearchResultSchema, SearchResponseSchema, SingleSkillResponseSchema, TelemetryResponseSchema, TrustTierSchema, StatsResponseSchema, } from './schemas.js'; export declare class SkillsmithApiClient { private baseUrl; private anonKey; private apiKey; private jwtToken; private timeout; private maxRetries; private debug; private offlineMode; /** SMI-4119: Lazily-initialized batcher for telemetry events. */ private eventBatcher; /** SMI-4120: Response cache (null when disabled). */ private responseCache; constructor(config?: ApiClientConfig); /** SMI-4120: Expose the response cache (null when disabled). */ getResponseCache(): ApiCache | null; isOffline(): boolean; hasPersonalApiKey(): boolean; getAuthMode(): 'jwt' | 'personal' | 'anonymous' | 'none'; /** SMI-4402: Update the JWT token (e.g. after a refresh). */ setJwtToken(token: string): void; private log; private request; search(options: SearchOptions, callOptions?: CallCacheOptions): Promise>; getSkill(id: string, options?: { includeContent?: boolean; } & CallCacheOptions): Promise>; getRecommendations(request: RecommendationRequest, callOptions?: CallCacheOptions): Promise>; syncRegistry(options?: RegistrySyncOptions): Promise>; getStats(): Promise>; recordEvent(event: TelemetryEvent): Promise<{ ok: boolean; }>; /** SMI-4119: Flush queued telemetry events (drain the batcher). */ flushEvents(): Promise; /** SMI-4119: Dispose batcher (detach exit listeners, clear timers). */ disposeEventBatcher(): void; private getOrCreateBatcher; checkHealth(): Promise<{ status: 'healthy' | 'degraded' | 'unhealthy'; timestamp: string; version: string; }>; static toSkill(result: ApiSearchResult): Skill; } export declare function createApiClient(config?: ApiClientConfig): SkillsmithApiClient; export default SkillsmithApiClient; //# sourceMappingURL=client.d.ts.map