/** * Elicitation Runner * * Executes MCP elicitation requests with comprehensive error handling * and fail-safe behavior. If elicitation fails for ANY reason, the * sanitized content is delivered — security is never compromised. * * Error handling includes: * - Client doesn't support elicitation * - Client timeout * - Network errors * - Unexpected responses * * Fail-safe principle: Elicitation is UX. Sanitization is security. * Never block content delivery due to elicitation failures. */ import type { Server } from '@modelcontextprotocol/sdk/server/index.js'; import type { ThreatReport } from './threat-reporter.js'; /** * Result of elicitation execution */ export interface ElicitationResult { /** Whether user chose to proceed with sanitized content */ proceed: boolean; /** Whether to include threat report in response */ includeReport: boolean; } /** * Runs MCP elicitation for CRITICAL threat confirmation * * Three possible outcomes: * 1. User accepts → proceed: true, includeReport: user's choice * 2. User declines → proceed: false, includeReport: false * 3. User cancels → proceed: false, includeReport: false * * Fail-safe: Any error → proceed: true, includeReport: true * (Content reaches user in sanitized form, security maintained) * * CRITICAL: Only ONE elicitation per tool call is allowed per MCP spec. * Calling this function twice in the same request will cause timeout. * * @param server The MCP server instance * @param threatReport The CRITICAL threat report * @param url The source URL * @returns Elicitation result with proceed and includeReport flags */ export declare function runElicitation(server: Server, threatReport: ThreatReport, url: string): Promise; //# sourceMappingURL=elicit-runner.d.ts.map