n8n-mcp
Version:
Integration between n8n workflow automation and Model Context Protocol (MCP)
23 lines • 979 B
TypeScript
import { SSEMessage, MCPSSEMessage, WorkflowContext } from '../types/sse';
export declare class SSESessionManager {
private clients;
private cleanupInterval;
private readonly CLEANUP_INTERVAL;
private readonly SESSION_TIMEOUT;
private readonly MAX_CLIENTS;
constructor();
registerClient(response: any): string;
removeClient(clientId: string): void;
sendToClient(clientId: string, message: SSEMessage): boolean;
sendMCPMessage(clientId: string, mcpMessage: MCPSSEMessage['data']): boolean;
broadcast(message: SSEMessage): void;
sendPing(clientId: string): boolean;
pingAllClients(): void;
private cleanupInactiveSessions;
hasClient(clientId: string): boolean;
getActiveClientCount(): number;
updateWorkflowContext(clientId: string, context: WorkflowContext): boolean;
getWorkflowContext(clientId: string): WorkflowContext | undefined;
shutdown(): void;
}
//# sourceMappingURL=sse-session-manager.d.ts.map