UNPKG

@toolprint/hypertool-mcp

Version:

HyperTool MCP proxy server for routing requests between clients and multiple underlying MCP servers

47 lines • 1.63 kB
/** * Logging system interfaces and types */ import { RuntimeOptions } from "../../types/runtime.js"; export type LogContext = Record<string, unknown> | string | number | boolean | null | undefined | Error | unknown; export type LogLevel = "fatal" | "error" | "warn" | "info" | "debug" | "trace"; export interface LoggingConfig { level: LogLevel; enableConsole: boolean; enableFile: boolean; serverName: string; format: "json" | "pretty"; } /** * Unified logger interface that both Pino and mcp-logger implementations must support */ export interface LoggerInterface { fatal(message: string, context?: LogContext): void; error(message: string, context?: LogContext): void; warn(message: string, context?: LogContext): void; info(message: string, context?: LogContext): void; debug(message: string, context?: LogContext): void; trace(message: string, context?: LogContext): void; child(bindings: { module?: string; [key: string]: unknown; }): LoggerInterface; updateConfig(config: Partial<LoggingConfig>): void; get pino(): any; get mcp(): any; } /** * Constructor interface for logger implementations */ export interface LoggerConstructor { new (config?: Partial<LoggingConfig>, runtimeOptions?: RuntimeOptions): LoggerInterface; } /** * Logger factory interface */ export interface LoggerFactory { createLogger(config?: Partial<LoggingConfig>, runtimeOptions?: RuntimeOptions): Promise<LoggerInterface>; createChildLogger(bindings: { module: string; }): LoggerInterface; } //# sourceMappingURL=interfaces.d.ts.map