mcpwn API
    Preparing search index...

    Interface ScanClient

    A thin MCP client the scanner drives. Both transports funnel every message through the shared pipeline for detection + correlation. Exported so the differential diff command (src/diff.ts) reuses the exact same handshake, id-correlation, ping handling, timeouts and clean shutdown.

    interface ScanClient {
        close(): Promise<void>;
        notify(method: string, params: unknown): void;
        request(
            method: string,
            params: unknown,
            timeoutMs: number,
        ): Promise<FlowMessage>;
    }
    Index
    • Clean shutdown — kill the child / release resources. Never hangs.

      Returns Promise<void>

    • Fire-and-forget notification (no reply expected).

      Parameters

      • method: string
      • params: unknown

      Returns void

    • Send a request and await its correlated reply (resolved via the correlator). Rejects on the per-call timeout.

      Parameters

      • method: string
      • params: unknown
      • timeoutMs: number

      Returns Promise<FlowMessage>