electron-agent-bridge
    Preparing search index...

    Module @electron-agent-bridge/client

    @electron-agent-bridge/client: Programmatic Node API: connect to or launch an app, typed BridgeApi, flow runner.

    @electron-agent-bridge/client

    npm

    The Node API of electron-agent-bridge: connect to an Electron app running the bridge, or launch one with it, and call the protocol with typed results.

    npm install --save-dev @electron-agent-bridge/client
    
    import { connect, launch } from '@electron-agent-bridge/client';

    // An app started with EAB_ENABLE=1 (Integrated mode):
    const app = await connect();
    const { data } = await app.call('snapshot.take', {});
    console.log(data.text);
    await app.call('action.run', { actions: [{ type: 'click', locator: { role: 'button', name: 'Save' } }] });

    // Or start an unmodified development build with the bridge injected (Launch mode):
    const launched = await launch({ executable: './node_modules/.bin/electron', args: ['.'] });
    await launched.client.call('targets.list', {});
    await launched.close();

    Also: listInstances() (running apps), YAML flows (parseFlow, FlowSchema), and toPlaywright(flow). Docs ยท MIT licensed.

    BridgeClient
    AppInstance
    CallOptions
    ConnectOptions
    FlowApi
    FlowResult
    FuseReport
    LaunchedApp
    LaunchOptions
    PlaywrightExport
    RecordedFlow
    RecordingToFlowOptions
    RpcCaller
    RunFlowFilesOptions
    RunFlowOptions
    StepOutcome
    CallableMethod
    Expectation
    Flow
    FlowApp
    FlowStep
    FuseState
    LaunchStrategy
    SessionInfo
    DEFAULT_STEP_TIMEOUT_MS
    FlowSchema
    FUSE_NAMES
    STRATEGY_FUSES
    asarOf
    blockedStrategies
    connect
    defaultEndpointDirectory
    describeStep
    findFlowFiles
    flowFromRecording
    fuseFileOf
    launch
    listInstances
    parseFlow
    readFuses
    readHandshake
    runFlow
    runFlowFiles
    stringifyFlow
    toJunit
    toPlaywright