@mcp-z/client
    Preparing search index...

    Interface ServerRegistry

    interface ServerRegistry {
        "[asyncDispose]": () => Promise<void>;
        clients: Set<ManagedClient>;
        close: (
            signal?: Signals,
            opts?: { timeoutMs?: number },
        ) => Promise<CloseResult>;
        config: ServersConfig;
        connect: (
            name: string,
            options?: {
                dcrAuthenticator?: Partial<DcrAuthenticatorOptions>;
                logger?: Logger;
            },
        ) => Promise<ManagedClient>;
        searchCapabilities: (
            query: string,
            options?: SearchOptions,
        ) => Promise<SearchResponse>;
    }
    Index
    "[asyncDispose]": () => Promise<void>

    Support for await using pattern (automatic close).

    clients: Set<ManagedClient>

    Set of connected clients tracked by this registry. Automatically populated when using registry.connect().

    close: (signal?: Signals, opts?: { timeoutMs?: number }) => Promise<CloseResult>

    Close all clients and servers gracefully. First closes all tracked clients, then sends the specified signal to all server processes.

    Type Declaration

      • (signal?: Signals, opts?: { timeoutMs?: number }): Promise<CloseResult>
      • Parameters

        • Optionalsignal: Signals

          Signal to send to processes (default: SIGINT)

        • Optionalopts: { timeoutMs?: number }

          Options including timeout

        Returns Promise<CloseResult>

        Promise resolving to whether any process timed out and how many were force-killed

    The resolved servers configuration that was used. Useful for debugging and understanding what was started.

    connect: (
        name: string,
        options?: {
            dcrAuthenticator?: Partial<DcrAuthenticatorOptions>;
            logger?: Logger;
        },
    ) => Promise<ManagedClient>

    Connect to a server by name. The connected client is automatically tracked for close.

    Type Declaration

    searchCapabilities: (
        query: string,
        options?: SearchOptions,
    ) => Promise<SearchResponse>

    Search indexed capabilities across all currently connected clients. Requires at least one connected client; respects SearchOptions filters.