@superadnim/osint-mcp-server
Version:
Professional OSINT MCP Server for intelligence gathering with privacy protection
24 lines • 977 B
TypeScript
import NodeCache from 'node-cache';
export interface CacheOptions {
ttl?: number;
checkperiod?: number;
}
export declare class CacheManager {
private cache;
private defaultTTL;
constructor(options?: CacheOptions);
set(key: string, value: unknown, ttl?: number): boolean;
get<T>(key: string): T | undefined;
has(key: string): boolean;
del(key: string): number;
clear(): void;
keys(): string[];
stats(): NodeCache.Stats;
generateKey(prefix: string, params: Record<string, unknown>): string;
memoize<T extends (...args: unknown[]) => Promise<unknown>>(fn: T, keyGenerator: (...args: Parameters<T>) => string, ttl?: number): T;
getOrSet<T>(key: string, fetchFn: () => Promise<T>, ttl?: number): Promise<T>;
setWithTags(key: string, value: unknown, tags: string[], ttl?: number): boolean;
deleteByTag(tag: string): number;
createInvestigationCache(): CacheManager;
}
//# sourceMappingURL=cache-manager.d.ts.map