CoAgent8 - Source API
    Preparing search index...

    Function withStdioRpc

    • Starts a probe with bounded output and requests, and awaits teardown on every exit.

      Type Parameters

      • T

      Parameters

      • command: string

        Executable or supported shim; no shell is invoked.

      • args: string[]

        Host/server arguments, without credentials in diagnostics.

      • operation: (
            rpc: {
                notify: (method: string, params?: unknown) => void;
                request: (method: string, params: unknown) => Promise<unknown>;
            },
        ) => Promise<T>

        Requests to issue after process startup.

      • options: { cwd?: string; env?: ProcessEnv; timeoutMs?: number } = {}

        Effective local environment, working directory, and request deadline.

      Returns Promise<T>

      The operation result after owned process cleanup.

      On malformed output, request deadline, process failure, or protocol errors.