import { type McpServer } from "../mcp/servers.js"; export declare const ECC_MCP_SELECTED: readonly ["code-review-graph", "codebase-memory-mcp", "context7", "serena"]; export declare const ECC_MCP_DISABLED: readonly ["ecc-memory-mcp", "github", "sequential-thinking", "token-savior"]; export declare const SERENA_RUNTIME_PIN: { readonly package: "serena-agent==1.7.0"; readonly sourceCommit: "949a27ef1e5fda1a6e7b561e777bcece345c6ffd"; readonly wheelSha256: "6dbf1459670d96fb0595f84932adef34260a6fe14ba5135b901fdb3c8c76e891"; readonly metadataSha256: "124f3562913efb9aa13d06ab92a64eb0a09c976490169e86b39d2c0b09b5643c"; }; interface SerenaRuntimePin { package: string; sourceCommit: string; wheelSha256: string; metadataSha256: string; } /** * The reviewed symbol/refactor surface. A fixed set is deliberate: Serena's * client contexts and modes are convenience defaults, not an authorization * boundary, and new upstream tools must not become available implicitly. */ export declare const SERENA_ALLOWED_TOOLS: readonly ["initial_instructions", "get_current_config", "restart_language_server", "get_symbols_overview", "find_symbol", "find_referencing_symbols", "find_implementations", "find_declaration", "get_diagnostics_for_file", "get_diagnostics_for_symbol", "replace_symbol_body", "insert_after_symbol", "insert_before_symbol", "rename_symbol", "safe_delete_symbol"]; /** The semantic floor every native context must expose at setup acceptance. */ export declare const SERENA_REQUIRED_TOOLS: readonly ["get_symbols_overview", "find_symbol", "find_referencing_symbols", "find_implementations"]; export declare const CONTEXT7_SUBJECT_SHA256: string; export interface EccMcpRemoteAttestation { endpoint: string; subjectSha256: string; reviewedAt: string; } export interface EccMcpProjectionInput { client: "claude" | "codex"; canonicalWorktree: string; serenaHome: string; /** Absolute root containing the authenticated pyproject.toml and uv.lock closure. */ serenaRuntimeRoot: string; /** Absolute path to the later AIH-owned launcher/protocol guard. */ wrapperCommand: string; /** Reviewed argv needed to reach the launcher within wrapperCommand. */ wrapperArgsPrefix?: readonly string[]; /** Digest verified by the later acquisition/materialization boundary. */ wrapperSha256: string; /** Authenticated resolver-lock digest produced by the acquisition boundary. */ serenaDependencyLockSha256: string; context7Attestation?: EccMcpRemoteAttestation; } export interface EccMcpProjection { activation: "prepared-not-registered"; servers: Record<(typeof ECC_MCP_SELECTED)[number], McpServer>; disabled: typeof ECC_MCP_DISABLED; serenaConfig: string; provenance: { serena: SerenaRuntimePin & { dependencyLockSha256: string; wrapperSha256: string; }; context7: EccMcpRemoteAttestation; }; native: { kind: "claude-json"; body: string; } | { kind: "codex-toml"; body: string; }; } export declare function renderSerenaConfig(): string; export declare function buildEccMcpProfileProjection(input: EccMcpProjectionInput): EccMcpProjection; /** Reconstructs only receipt-owned 1.6.1 fragments; new runtime projection always uses 1.7.0. */ export declare function buildSerena161ReceiptProjection(input: EccMcpProjectionInput): EccMcpProjection; interface SerenaToolDescription { name: string; [key: string]: unknown; } export declare function filterSerenaToolsList(value: unknown): { tools: SerenaToolDescription[]; }; export declare function guardSerenaToolCall(name: string): { allowed: true; } | { allowed: false; code: -32601; message: string; }; export type SerenaMcpRequestDecision = { forward: true; } | { forward: false; response: { jsonrpc: "2.0"; id: string | number | null; error: { code: -32601; message: string; }; }; }; /** * Protocol-level guard used by the later managed launcher. Client-native tool * filters remain defense in depth; this decision is the hard boundary. */ export declare class SerenaMcpPolicyGuard { inspectClientRequest(value: unknown): SerenaMcpRequestDecision; filterToolsList(value: unknown): { tools: SerenaToolDescription[]; }; } export declare function mergeEccMcpServers(operator: Readonly>, managed: Readonly>): Record; export type EccMcpHealth = { mode: "ordinary"; status: "advisory"; failedServers: string[]; } | { mode: "setup-acceptance"; status: "ready" | "blocked"; failedServers: string[]; }; export declare function evaluateEccMcpHealth(mode: EccMcpHealth["mode"], initialized: Readonly>): EccMcpHealth; /** Path is within root without treating prefix siblings as descendants. */ export declare function isWithinEccMcpRoot(root: string, candidate: string): boolean; export {};