@browserbridge/bbx 1.9.0 → 1.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +8 -10
- package/packages/agent-client/src/cli-args.js +35 -6
- package/packages/agent-client/src/cli-batch.js +10 -5
- package/packages/agent-client/src/cli-helpers.js +8 -0
- package/packages/agent-client/src/cli-proxy-remote.js +7 -4
- package/packages/agent-client/src/cli-setup-commands.js +3 -1
- package/packages/agent-client/src/cli.js +35 -15
- package/packages/agent-client/src/command-registry.js +7 -3
- package/packages/agent-client/src/mcp-config.js +8 -8
- package/packages/agent-client/src/npm-self-update.js +9 -2
- package/packages/agent-client/src/runtime.js +14 -5
- package/packages/agent-client/src/types.ts +2 -0
- package/packages/mcp-server/src/bin.js +1 -1
- package/packages/mcp-server/src/guidance.js +43 -6
- package/packages/mcp-server/src/handlers-capture.js +1 -1
- package/packages/mcp-server/src/handlers-page.js +162 -9
- package/packages/mcp-server/src/handlers-utils.js +145 -169
- package/packages/mcp-server/src/handlers.js +17 -5
- package/packages/mcp-server/src/server.js +255 -91
- package/packages/mcp-server/src/toolset.js +73 -0
- package/packages/native-host/src/daemon.js +24 -107
- package/packages/native-host/src/dom-baseline-owners.js +210 -0
- package/packages/native-host/src/native-host.js +14 -28
- package/packages/protocol/src/budget-presets.js +182 -0
- package/packages/protocol/src/har.js +34 -0
- package/packages/protocol/src/index.js +2 -0
- package/packages/protocol/src/json-lines.js +3 -2
- package/packages/protocol/src/protocol.js +10 -0
- package/packages/protocol/src/registry.js +83 -0
- package/packages/protocol/src/types.ts +3 -0
- package/skills/browser-bridge/SKILL.md +4 -0
- package/skills/browser-bridge/references/protocol.md +11 -5
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
// @ts-check
|
|
2
2
|
|
|
3
3
|
import os from 'node:os';
|
|
4
|
+
|
|
4
5
|
import { DEFAULT_LOG_TAIL_LIMIT, createRuntimeContext } from '../../protocol/src/index.js';
|
|
5
6
|
import { collectSetupStatus } from '../../agent-client/src/setup-status.js';
|
|
6
7
|
import {
|
|
@@ -10,6 +11,7 @@ import {
|
|
|
10
11
|
getToolTokenBudget,
|
|
11
12
|
getBridgeDestinations,
|
|
12
13
|
applyLimitBudgetPreset,
|
|
14
|
+
requestBridgeWithRetry,
|
|
13
15
|
summarizeToolError,
|
|
14
16
|
summarizeToolResponse,
|
|
15
17
|
withToolClient,
|
|
@@ -33,6 +35,7 @@ export {
|
|
|
33
35
|
callBridgeTool,
|
|
34
36
|
dispatchToolAction,
|
|
35
37
|
REQUEST_SOURCE,
|
|
38
|
+
runWithMcpRequestEra,
|
|
36
39
|
} from './handlers-utils.js';
|
|
37
40
|
|
|
38
41
|
export {
|
|
@@ -56,6 +59,8 @@ export {
|
|
|
56
59
|
export {
|
|
57
60
|
PAGE_ACTIONS,
|
|
58
61
|
handlePageTool,
|
|
62
|
+
handleArtifactTool,
|
|
63
|
+
handleInterceptTool,
|
|
59
64
|
handleSensitiveReadTool,
|
|
60
65
|
handleBatchTool,
|
|
61
66
|
handleRawCallTool,
|
|
@@ -194,7 +199,10 @@ export async function handleSetupTool(args) {
|
|
|
194
199
|
const configuredMcp = status.mcpClients.filter((e) => e.configured).length;
|
|
195
200
|
const installedSkills = status.skillTargets.filter((e) => e.installed).length;
|
|
196
201
|
const summary = `Optional agent integration status: ${configuredMcp}/${status.mcpClients.length} MCP clients configured, ${installedSkills}/${status.skillTargets.length} skills installed.`;
|
|
197
|
-
return createToolResult(summary, {
|
|
202
|
+
return createToolResult(summary, {
|
|
203
|
+
ok: true,
|
|
204
|
+
status,
|
|
205
|
+
});
|
|
198
206
|
}
|
|
199
207
|
|
|
200
208
|
/**
|
|
@@ -227,10 +235,14 @@ export async function handleHealthTool(args = {}) {
|
|
|
227
235
|
const destinationId = typeof args.destinationId === 'string' ? args.destinationId : null;
|
|
228
236
|
return withToolClient(
|
|
229
237
|
async (client) => {
|
|
230
|
-
const response = await
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
238
|
+
const response = await requestBridgeWithRetry(
|
|
239
|
+
client,
|
|
240
|
+
'health.ping',
|
|
241
|
+
{},
|
|
242
|
+
{
|
|
243
|
+
source: REQUEST_SOURCE,
|
|
244
|
+
}
|
|
245
|
+
);
|
|
234
246
|
return summarizeToolResponse(response, 'health.ping');
|
|
235
247
|
},
|
|
236
248
|
{ destinationId }
|