auto-chrome-mcp-shared 1.10.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/dist/index.js CHANGED
@@ -75,6 +75,8 @@ var NativeMessageType = /* @__PURE__ */ ((NativeMessageType2) => {
75
75
  var TOOL_NAMES = {
76
76
  BROWSER: {
77
77
  GET_WINDOWS_AND_TABS: "get_windows_and_tabs",
78
+ // Hidden from TOOL_SCHEMAS (schema-size reduction, v1.10.1) — still dispatch-registered
79
+ // and fully implemented (vector-search.ts). See docs/TOOLS.md "Hidden Tools".
78
80
  SEARCH_TABS_CONTENT: "search_tabs_content",
79
81
  NAVIGATE: "chrome_navigate",
80
82
  SCREENSHOT: "chrome_screenshot",
@@ -84,6 +86,9 @@ var TOOL_NAMES = {
84
86
  CLICK: "chrome_click_element",
85
87
  FILL: "chrome_fill_or_select",
86
88
  REQUEST_ELEMENT_SELECTION: "chrome_request_element_selection",
89
+ // Deprecated, hidden from TOOL_SCHEMAS — chrome_read_page replaces it as the primary
90
+ // discovery tool (and falls back to this logic internally when needed). Kept only for
91
+ // backward compatibility. See docs/TOOLS.md "Hidden Tools".
87
92
  GET_INTERACTIVE_ELEMENTS: "chrome_get_interactive_elements",
88
93
  NETWORK_CAPTURE: "chrome_network_capture",
89
94
  // Legacy tool names (kept for internal use, not exposed in TOOL_SCHEMAS)
@@ -97,6 +102,9 @@ var TOOL_NAMES = {
97
102
  BOOKMARK_SEARCH: "chrome_bookmark_search",
98
103
  BOOKMARK_ADD: "chrome_bookmark_add",
99
104
  BOOKMARK_DELETE: "chrome_bookmark_delete",
105
+ // Hidden from TOOL_SCHEMAS (schema-size reduction, v1.10.1) — still dispatch-registered
106
+ // and fully implemented (inject-script.ts); also used internally by the record-replay
107
+ // engine. See docs/TOOLS.md "Hidden Tools".
100
108
  INJECT_SCRIPT: "chrome_inject_script",
101
109
  SEND_COMMAND_TO_INJECT_SCRIPT: "chrome_send_command_to_inject_script",
102
110
  JAVASCRIPT: "chrome_javascript",
@@ -107,6 +115,8 @@ var TOOL_NAMES = {
107
115
  HANDLE_DIALOG: "chrome_handle_dialog",
108
116
  HANDLE_DOWNLOAD: "chrome_handle_download",
109
117
  REQUEST_USER_CONSENT: "chrome_request_user_consent",
118
+ // Hidden from TOOL_SCHEMAS (schema-size reduction, v1.10.1) — still dispatch-registered
119
+ // and fully implemented (userscript.ts). See docs/TOOLS.md "Hidden Tools".
110
120
  USERSCRIPT: "chrome_userscript",
111
121
  PERFORMANCE_START_TRACE: "performance_start_trace",
112
122
  PERFORMANCE_STOP_TRACE: "performance_stop_trace",
@@ -133,28 +143,62 @@ var TOOL_NAMES = {
133
143
  LIST_PUBLISHED: "record_replay_list_published"
134
144
  }
135
145
  };
146
+ var P_TAB_ID = "Tab id; omit to use the session work tab.";
147
+ var P_WINDOW_ID = "Window to pick the active tab from when tabId is omitted.";
148
+ var P_FRAME_ID = "Target frame id (iframe).";
149
+ var P_SELECTOR_TYPE = 'Selector type (default "css").';
150
+ var P_WAIT_FOR_ELEMENT_MS = "Ms to wait for the element to appear/become visible before failing (default 2000; 0 = fail now).";
151
+ var P_BACKGROUND = "Do not activate the tab or focus the window (default false).";
152
+ var P_STEP_AS = "Name this step result so later steps can read it.";
153
+ var P_TEMPLATES = 'Enable {{name.path}} substitution in step args, e.g. ref: "{{hit.matches[0].ref}}". Auto on when any step has "as".';
154
+ var P_RETURN = 'Names to include in the response "results" object.';
155
+ var P_WHEN = 'Run only if this condition holds, e.g. { path: "hit.matches", op: "notEmpty" }. Otherwise the step is skipped.';
156
+ var P_STOP_IF = "Stop the whole run after this step when the condition holds.";
157
+ var P_REPEAT = 'Repeat group: { max: 1-20, until?: condition, delayMs?: 0-5000 } together with a "steps" array.';
158
+ var P_GROUP_STEPS = "Steps of a repeat group (no repeat inside a repeat).";
159
+ var P_PARAMS = "save: declare { user: { required: true }, pw: { secret: true } }. run: values for {{params.user}}.";
160
+ var tabIdProp = { type: "number", description: P_TAB_ID };
161
+ var windowIdProp = { type: "number", description: P_WINDOW_ID };
162
+ var frameIdProp = { type: "number", description: P_FRAME_ID };
163
+ var selectorTypeProp = {
164
+ type: "string",
165
+ enum: ["css", "xpath"],
166
+ description: P_SELECTOR_TYPE
167
+ };
168
+ var waitForElementMsProp = { type: "number", description: P_WAIT_FOR_ELEMENT_MS };
169
+ var backgroundProp = { type: "boolean", description: P_BACKGROUND };
136
170
  var TOOL_SCHEMAS = [
137
171
  {
138
172
  name: TOOL_NAMES.BROWSER.BATCH,
139
- description: "Execute multiple browser tool steps sequentially in ONE call (cuts round-trip latency for chains like click \u2192 fill \u2192 click \u2192 screenshot). Each step targets the session work tab by default. Steps cannot include chrome_batch itself or interactive tools (switch_tab, element selection, user consent). Default stops on first error; set continueOnError to run all steps. Returns per-step results as JSON.",
173
+ description: "Run several browser steps in ONE call (fewer round-trips for chains like click -> fill -> screenshot). Steps target the session work tab. Cannot nest chrome_batch or interactive tools (switch_tab, element selection, consent). Stops on first error unless continueOnError. Returns per-step JSON.",
140
174
  inputSchema: {
141
175
  type: "object",
142
176
  properties: {
143
177
  steps: {
144
178
  type: "array",
145
- description: "Steps to run in order (max 20). Each: { tool: string, args?: object }",
179
+ description: "Steps in order (max 20). Each: { tool: string, args?: object }, or a repeat group { repeat: {...}, steps: [...] }",
146
180
  items: {
147
181
  type: "object",
148
182
  properties: {
149
183
  tool: { type: "string", description: "Tool name, e.g. chrome_click_element" },
150
- args: { type: "object", description: "Arguments for the tool" }
151
- },
152
- required: ["tool"]
184
+ args: { type: "object", description: "Arguments for the tool" },
185
+ as: { type: "string", description: P_STEP_AS },
186
+ when: { type: "object", description: P_WHEN },
187
+ stopIf: { type: "object", description: P_STOP_IF },
188
+ repeat: { type: "object", description: P_REPEAT },
189
+ steps: { type: "array", description: P_GROUP_STEPS }
190
+ }
153
191
  }
154
192
  },
155
193
  continueOnError: {
156
194
  type: "boolean",
157
- description: "Run remaining steps even when a step fails (default false)"
195
+ description: "Keep running after a step fails (default false)"
196
+ },
197
+ templates: { type: "boolean", description: P_TEMPLATES },
198
+ return: {
199
+ type: "array",
200
+ items: { type: "string" },
201
+ description: P_RETURN
158
202
  }
159
203
  },
160
204
  required: ["steps"]
@@ -162,7 +206,7 @@ var TOOL_SCHEMAS = [
162
206
  },
163
207
  {
164
208
  name: TOOL_NAMES.BROWSER.FIND,
165
- description: 'Find elements on the page using natural language (Korean or English), e.g. "\uB85C\uADF8\uC778 \uBC84\uD2BC", "search input", "\uC7A5\uBC14\uAD6C\uB2C8 \uC544\uC774\uCF58". Matches element names/roles/placeholder/text via synonym + fuzzy scoring over the accessibility tree and returns ranked candidates with ref (usable directly in chrome_click_element / chrome_fill_or_select), role, name, coordinates, and frameId. Cheaper and more direct than reading the whole page when you know what you are looking for.',
209
+ description: 'Find elements by natural-language query (Korean/English, e.g. "\uB85C\uADF8\uC778 \uBC84\uD2BC", "search input"). Returns ranked candidates with ref (usable in chrome_click_element / chrome_fill_or_select), role, name, coordinates, frameId. Cheaper than reading the whole page when you know the target.',
166
210
  inputSchema: {
167
211
  type: "object",
168
212
  properties: {
@@ -170,11 +214,8 @@ var TOOL_SCHEMAS = [
170
214
  type: "string",
171
215
  description: "Natural language description of the element (Korean/English)"
172
216
  },
173
- tabId: {
174
- type: "number",
175
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
176
- },
177
- maxResults: { type: "number", description: "Max candidates to return (default 5, max 20)" },
217
+ tabId: tabIdProp,
218
+ maxResults: { type: "number", description: "Max candidates (default 5, max 20)" },
178
219
  allFrames: {
179
220
  type: "boolean",
180
221
  description: "Also search inside iframes (default true)"
@@ -185,7 +226,7 @@ var TOOL_SCHEMAS = [
185
226
  },
186
227
  {
187
228
  name: TOOL_NAMES.BROWSER.SHORTCUT,
188
- description: 'Save and run named multi-step shortcuts (macro = a chrome_batch step list stored under a name). action="save" stores {name, steps, description}; "run" executes a saved shortcut through the normal tool pipeline; "list" shows saved shortcuts; "delete" removes one. Useful for workflows you repeat across sessions (login flows, routine collection).',
229
+ description: "Save and run named macros (a chrome_batch step list stored under a name). action: save {name, steps, description} | run (through the normal pipeline) | list | delete. Use for flows you repeat across sessions (logins, routine collection).",
189
230
  inputSchema: {
190
231
  type: "object",
191
232
  properties: {
@@ -197,57 +238,59 @@ var TOOL_SCHEMAS = [
197
238
  name: { type: "string", description: "Shortcut name (save/run/delete)" },
198
239
  steps: {
199
240
  type: "array",
200
- description: 'For action="save": steps in chrome_batch format, max 20. Each: { tool: string, args?: object }',
241
+ description: 'action="save": chrome_batch steps, max 20. Each: { tool: string, args?: object }, or a repeat group',
201
242
  items: {
202
243
  type: "object",
203
244
  properties: {
204
245
  tool: { type: "string" },
205
- args: { type: "object" }
206
- },
207
- required: ["tool"]
246
+ args: { type: "object" },
247
+ as: { type: "string", description: P_STEP_AS },
248
+ when: { type: "object", description: P_WHEN },
249
+ stopIf: { type: "object", description: P_STOP_IF },
250
+ repeat: { type: "object", description: P_REPEAT },
251
+ steps: { type: "array", description: P_GROUP_STEPS }
252
+ }
208
253
  }
209
254
  },
210
- description: { type: "string", description: 'For action="save": what this shortcut does' },
255
+ description: { type: "string", description: 'action="save": what this shortcut does' },
211
256
  continueOnError: {
212
257
  type: "boolean",
213
- description: 'For action="run": keep running steps after a failure (default false)'
214
- }
258
+ description: 'action="run": keep running after a failure (default false)'
259
+ },
260
+ templates: { type: "boolean", description: P_TEMPLATES },
261
+ return: {
262
+ type: "array",
263
+ items: { type: "string" },
264
+ description: P_RETURN
265
+ },
266
+ params: { type: "object", description: P_PARAMS }
215
267
  },
216
268
  required: ["action"]
217
269
  }
218
270
  },
219
271
  {
220
272
  name: TOOL_NAMES.BROWSER.EXTRACT,
221
- description: "Extract ONLY the fields you need from the page via CSS selectors \u2014 far cheaper than reading the whole page when you know what you want (e.g. price, title, links). Deterministic and precise. Prefer this over chrome_get_web_content/chrome_read_page for targeted scraping.",
273
+ description: "Extract ONLY the fields you need via CSS selectors, far cheaper than reading the whole page (e.g. price, title, links). Prefer over chrome_get_web_content / chrome_read_page for targeted scraping.",
222
274
  inputSchema: {
223
275
  type: "object",
224
276
  properties: {
225
- tabId: {
226
- type: "number",
227
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
228
- },
277
+ tabId: tabIdProp,
229
278
  fields: {
230
279
  type: "object",
231
- description: "Map of fieldName \u2192 CSS selector (string) or { selector, attr?, all? }. Default value = trimmed innerText of first match; attr returns that attribute (href/src resolve to absolute URLs); all:true returns an array over every match (max 100, 2000 chars each). Max 20 fields."
280
+ description: "Map of fieldName -> CSS selector (string) or { selector, attr?, all? }. Default = trimmed innerText of first match; attr returns that attribute (href/src become absolute URLs); all:true returns an array over every match (max 100, 2000 chars each). Max 20 fields."
232
281
  },
233
- frameId: {
234
- type: "number",
235
- description: "Optional frame id to extract from a specific iframe."
236
- }
282
+ frameId: frameIdProp
237
283
  },
238
284
  required: ["fields"]
239
285
  }
240
286
  },
241
287
  {
242
288
  name: TOOL_NAMES.BROWSER.WAIT_FOR,
243
- description: 'Wait until the page is actually ready before acting \u2014 prevents "clicked/read too early" failures after navigation, clicks, or AJAX updates. Conditions (AND-combined, at least one required): selector appears/visible/hidden, text appears, document ready, or network idle. A timeout returns success:false with the observed state (not an error) so you can decide next steps.',
289
+ description: 'Wait until the page is ready before acting, avoiding "acted too early" failures after navigation/clicks/AJAX. Conditions (AND-combined, at least one required): selector state, text appears, document ready, or network idle. A timeout returns success:false with the observed state (not an error).',
244
290
  inputSchema: {
245
291
  type: "object",
246
292
  properties: {
247
- tabId: {
248
- type: "number",
249
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
250
- },
293
+ tabId: tabIdProp,
251
294
  selector: { type: "string", description: "CSS selector to wait for" },
252
295
  state: {
253
296
  type: "string",
@@ -261,7 +304,7 @@ var TOOL_SCHEMAS = [
261
304
  },
262
305
  networkIdleMs: {
263
306
  type: "number",
264
- description: "Wait until the tab has no in-flight network requests for this many ms (e.g. 500)"
307
+ description: "Wait until no in-flight requests for this many ms (e.g. 500)"
265
308
  },
266
309
  timeoutMs: { type: "number", description: "Max wait (default 15000, max 60000)" },
267
310
  pollMs: { type: "number", description: "Poll interval (default 250, min 100)" }
@@ -271,18 +314,15 @@ var TOOL_SCHEMAS = [
271
314
  },
272
315
  {
273
316
  name: TOOL_NAMES.BROWSER.SCROLL_COLLECT,
274
- description: "Collect content from infinite-scroll / lazy-loaded pages in ONE call: repeatedly scrolls to the bottom (window or a container element), waits for new content, and returns the accumulated text or links. Stops when the page stops growing, stopText appears, maxScrolls or maxChars is reached.",
317
+ description: "Collect content from infinite-scroll / lazy-loaded pages in ONE call: repeatedly scrolls to the bottom (window or a container), waits for new content, returns accumulated text or links. Stops when the page stops growing, stopText appears, or maxScrolls/maxChars is reached.",
275
318
  inputSchema: {
276
319
  type: "object",
277
320
  properties: {
278
- tabId: {
279
- type: "number",
280
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
281
- },
321
+ tabId: tabIdProp,
282
322
  maxScrolls: { type: "number", description: "Max scroll passes (default 10, max 30)" },
283
323
  delayMs: {
284
324
  type: "number",
285
- description: "Wait after each scroll for content to load (default 700, 200\u20133000)"
325
+ description: "Wait after each scroll for content to load (default 700, 200-3000)"
286
326
  },
287
327
  containerSelector: {
288
328
  type: "string",
@@ -298,7 +338,7 @@ var TOOL_SCHEMAS = [
298
338
  renderMode: {
299
339
  type: "string",
300
340
  enum: ["auto", "force", "off"],
301
- description: "Keep a background tab rendering so lazy loading actually fires (Chrome stops producing frames in inactive tabs, so IntersectionObserver never triggers). 'auto' (default) = enable only when the tab is not visible, 'force' = always, 'off' = never. Uses CDP, which shows a debugging infobar on that tab."
341
+ description: "Keep a background tab rendering so lazy loading fires (inactive tabs stop producing frames, so IntersectionObserver never triggers). 'auto' (default) = only when hidden, 'force' = always, 'off' = never. Uses CDP (shows a debug infobar)."
302
342
  }
303
343
  },
304
344
  required: []
@@ -306,7 +346,7 @@ var TOOL_SCHEMAS = [
306
346
  },
307
347
  {
308
348
  name: TOOL_NAMES.BROWSER.SET_WORK_TAB,
309
- description: "Retarget this session's default work tab WITHOUT activating/focusing anything (unlike chrome_switch_tab). Use when a tool result reports new_tabs_opened (a popup/new tab appeared, e.g. OAuth login) and you want subsequent tabId-less tool calls to target it \u2014 then call again with the original tabId to return. No args = report current work tab. clear:true = unset.",
349
+ description: "Retarget this session's default work tab WITHOUT focusing anything (unlike chrome_switch_tab). Use when a result reports new_tabs_opened (a popup/new tab, e.g. OAuth) so later tabId-less calls target it; call again with the original tabId to return. No args = report current; clear:true = unset.",
310
350
  inputSchema: {
311
351
  type: "object",
312
352
  properties: {
@@ -324,139 +364,109 @@ var TOOL_SCHEMAS = [
324
364
  },
325
365
  {
326
366
  name: TOOL_NAMES.BROWSER.GET_WINDOWS_AND_TABS,
327
- description: "Get all currently open browser windows and tabs. Marks MCP session work tabs (mcpWorkTabSessions), the dedicated MCP work window (isMcpWorkWindow), and tabs recently spawned by page actions such as popups (recentlySpawned with openerTabId).",
367
+ description: "Get all open windows and tabs. Marks MCP session work tabs (mcpWorkTabSessions), the dedicated MCP work window (isMcpWorkWindow), and tabs recently spawned by page actions like popups (recentlySpawned with openerTabId).",
328
368
  inputSchema: {
329
369
  type: "object",
330
370
  properties: {},
331
371
  required: []
332
372
  }
333
373
  },
374
+ // record_replay 두 도구는 **의도적으로 MCP 에 노출하지 않는다** (2026-09-04 Codex 3차 검토, 항목 3).
375
+ //
376
+ // replay 엔진은 대상 탭을 스스로 고른다 — rr-utils 의 ensureTab() 이 tabTarget 미지정·'current'
377
+ // 에서 사용자의 활성 탭을 잡고, legacy step executor 와 대부분의 노드(click·fill·extract·
378
+ // assert·script·wait·drag 등)가 ctx.tabId 를 무시하고 같은 조회를 다시 한다(엔진·노드 전체
379
+ // 28곳/16파일). 그래서 백그라운드 작업 게이트가 작업 탭 id 를 주입해도 소비하는 지점이 없고,
380
+ // flow_run 호출이 사용자가 보고 있는 탭을 조작한다. 엔진이 ctx.tabId 를 존중하도록 고치기 전에는
381
+ // 노출하지 않으며, 확장의 게이트도 백그라운드 모드에서 flow_run 을 거절한다
382
+ // (utils/work-tab-gate.ts 의 BACKGROUND_MODE_UNSUPPORTED_TOOLS).
383
+ //
334
384
  // {
335
385
  // name: TOOL_NAMES.RECORD_REPLAY.FLOW_RUN,
336
- // description:
337
- // 'Run a recorded flow by ID with optional variables and run options. Returns a standardized run result.',
338
- // inputSchema: {
339
- // type: 'object',
340
- // properties: {
341
- // flowId: { type: 'string', description: 'ID of the flow to run' },
342
- // args: {
343
- // type: 'object',
344
- // description: 'Variable values for the flow (flat object of key/value)',
345
- // },
346
- // tabTarget: {
347
- // type: 'string',
348
- // description: "Target tab: 'current' or 'new' (default: current)",
349
- // enum: ['current', 'new'],
350
- // },
351
- // refresh: { type: 'boolean', description: 'Refresh before running (default false)' },
352
- // captureNetwork: {
353
- // type: 'boolean',
354
- // description: 'Capture network snippets for debugging (default false)',
355
- // },
356
- // returnLogs: { type: 'boolean', description: 'Return run logs (default false)' },
357
- // timeoutMs: { type: 'number', description: 'Global timeout in ms (optional)' },
358
- // startUrl: { type: 'string', description: 'Optional start URL to open before running' },
359
- // },
360
- // required: ['flowId'],
361
- // },
386
+ // ...
362
387
  // },
363
388
  // {
364
389
  // name: TOOL_NAMES.RECORD_REPLAY.LIST_PUBLISHED,
365
- // description: 'List published flows available as dynamic tools (for discovery).',
366
- // inputSchema: {
367
- // type: 'object',
368
- // properties: {},
369
- // required: [],
370
- // },
390
+ // ...
371
391
  // },
372
392
  {
373
393
  name: TOOL_NAMES.BROWSER.PERFORMANCE_START_TRACE,
374
- description: "Starts a performance trace recording on the selected page. Optionally reloads the page and/or auto-stops after a short duration.",
394
+ description: "Start a performance trace on the selected page. Optionally reload and/or auto-stop after a short duration.",
375
395
  inputSchema: {
376
396
  type: "object",
377
397
  properties: {
378
398
  reload: {
379
399
  type: "boolean",
380
- description: "Determines if, once tracing has started, the page should be automatically reloaded (ignore cache)."
400
+ description: "Reload the page (ignoring cache) once tracing starts."
381
401
  },
382
402
  autoStop: {
383
403
  type: "boolean",
384
- description: "Determines if the trace should be automatically stopped (default false)."
404
+ description: "Automatically stop the trace (default false)."
385
405
  },
386
406
  durationMs: {
387
407
  type: "number",
388
- description: "Auto-stop duration in milliseconds when autoStop is true (default 5000)."
408
+ description: "Auto-stop duration in ms when autoStop is true (default 5000)."
389
409
  },
390
- tabId: {
391
- type: "number",
392
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
393
- }
410
+ tabId: tabIdProp
394
411
  },
395
412
  required: []
396
413
  }
397
414
  },
398
415
  {
399
416
  name: TOOL_NAMES.BROWSER.PERFORMANCE_STOP_TRACE,
400
- description: "Stops the active performance trace recording on the selected page.",
417
+ description: "Stop the active performance trace on the selected page.",
401
418
  inputSchema: {
402
419
  type: "object",
403
420
  properties: {
404
421
  saveToDownloads: {
405
422
  type: "boolean",
406
- description: "Whether to save the trace as a JSON file in Downloads (default true)."
423
+ description: "Save the trace as a JSON file in Downloads (default true)."
407
424
  },
408
425
  filenamePrefix: {
409
426
  type: "string",
410
427
  description: "Optional filename prefix for the downloaded trace JSON."
411
428
  },
412
- tabId: {
413
- type: "number",
414
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
415
- }
429
+ tabId: tabIdProp
416
430
  },
417
431
  required: []
418
432
  }
419
433
  },
420
434
  {
421
435
  name: TOOL_NAMES.BROWSER.PERFORMANCE_ANALYZE_INSIGHT,
422
- description: "Provides a lightweight summary of the last recorded trace. For deep insights (CWV, breakdowns), integrate native-side DevTools trace engine.",
436
+ description: "Lightweight summary of the last recorded trace. Deep insights (CWV, breakdowns) need the native DevTools trace engine.",
423
437
  inputSchema: {
424
438
  type: "object",
425
439
  properties: {
426
440
  insightName: {
427
441
  type: "string",
428
- description: 'Optional insight name for future deep analysis (e.g., "DocumentLatency"). Currently informational only.'
442
+ description: 'Insight name for future deep analysis (e.g. "DocumentLatency").'
429
443
  },
430
444
  timeoutMs: {
431
445
  type: "number",
432
- description: "Timeout for deep analysis via native host (milliseconds). Default 60000. Increase for large traces."
446
+ description: "Native-host deep-analysis timeout in ms (default 60000)."
433
447
  },
434
- tabId: {
435
- type: "number",
436
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
437
- }
448
+ tabId: tabIdProp
438
449
  },
439
450
  required: []
440
451
  }
441
452
  },
442
453
  {
443
454
  name: TOOL_NAMES.BROWSER.READ_PAGE,
444
- description: `Get an accessibility tree representation of visible elements on the page. Only returns elements that are visible in the viewport. Optionally filter for only interactive elements.
445
- Tip: If the returned elements do not include the specific element you need, use the computer tool's screenshot (action="screenshot") to capture the element's on-screen coordinates, then operate by coordinates.`,
455
+ description: 'Accessibility-tree view of the elements visible in the viewport; optional interactive-only filter. Prefer over a screenshot for locating/acting on elements; use chrome_extract for known fields, chrome_find for a natural-language lookup.\nCompact format (default, lossless): 1 space indent per tree level; the bare token ref_N is the element ref (pass as refId, or as ref to click/fill/computer); @x,y is the element center; empty wrappers collapsed. compact:false for verbose. With allFrames, sections read "=== frame <frameId> | <url> ===" and refs inside are frame-local (pass that frameId).\nIf an element is missing, screenshot (chrome_computer action="screenshot") for its coordinates. markedElements are user-marked with highest priority.',
446
456
  inputSchema: {
447
457
  type: "object",
448
458
  properties: {
449
459
  filter: {
450
460
  type: "string",
451
- description: 'Filter elements: "interactive" for such as buttons/links/inputs only (default: all visible elements)'
461
+ description: '"interactive" for buttons/links/inputs only (default: all visible elements)'
452
462
  },
453
463
  depth: {
454
464
  type: "number",
455
- description: "Maximum DOM depth to traverse (integer >= 0). Lower values reduce output size and can improve performance."
465
+ description: "Max DOM depth to traverse (integer >= 0). Lower = smaller output."
456
466
  },
457
467
  refId: {
458
468
  type: "string",
459
- description: 'Focus on the subtree rooted at this element refId (e.g., "ref_12"). The refId must come from a recent chrome_read_page response in the same tab (refs may expire).'
469
+ description: 'Focus on the subtree at this refId (e.g. "ref_12"), from a recent read of the same tab (refs may expire).'
460
470
  },
461
471
  tabId: {
462
472
  type: "number",
@@ -468,15 +478,15 @@ Tip: If the returned elements do not include the specific element you need, use
468
478
  },
469
479
  allFrames: {
470
480
  type: "boolean",
471
- description: "Also collect content from iframes (merged, annotated with frameId \u2014 pair frame-local refs with that frameId). Default: false"
481
+ description: "Also collect from iframes (merged, annotated with frameId). Default: false"
472
482
  },
473
483
  diff: {
474
484
  type: "boolean",
475
- description: "When true (default), returns {unchanged:true} instead of the full body if the page content is identical to your previous read \u2014 reuse the earlier content. Pass false to force full re-send."
485
+ description: "When true (default), returns {unchanged:true} if the page is identical to your last read; false forces re-send."
476
486
  },
477
487
  compact: {
478
488
  type: "boolean",
479
- description: "Lossless output compaction (collapse empty wrappers etc., ~30-50% smaller). Default: true. Pass false for the verbose format."
489
+ description: "Lossless compaction (~30-50% smaller). Default: true; false for verbose."
480
490
  }
481
491
  },
482
492
  required: []
@@ -484,34 +494,34 @@ Tip: If the returned elements do not include the specific element you need, use
484
494
  },
485
495
  {
486
496
  name: TOOL_NAMES.BROWSER.COMPUTER,
487
- description: "Use a mouse and keyboard to interact with a web browser, and take screenshots.\n* Whenever you intend to click on an element like an icon, you should consult a read_page to determine the ref of the element before moving the cursor.\n* If you tried clicking on a program or link but it failed to load, even after waiting, try screenshot and then adjusting your click location so that the tip of the cursor visually falls on the element that you want to click.\n* Make sure to click any buttons, links, icons, etc with the cursor tip in the center of the element. Don't click boxes on their edges unless asked.",
497
+ description: "Mouse/keyboard interaction and screenshots. Before clicking (especially an icon), get its ref from chrome_read_page. If a click misses, screenshot and aim the cursor tip at the target center.",
488
498
  inputSchema: {
489
499
  type: "object",
490
500
  properties: {
491
501
  tabId: { type: "number", description: "Target tab ID (default: active tab)" },
492
502
  background: {
493
503
  type: "boolean",
494
- description: "Avoid focusing/activating tab/window for certain operations (best-effort). Default: false"
504
+ description: "Avoid focusing/activating the tab or window where possible. Default: false"
495
505
  },
496
506
  fullResolution: {
497
507
  type: "boolean",
498
- description: 'For action="screenshot"/"zoom": skip the \u22641568px downscale of the returned image (default: false)'
508
+ description: "screenshot/zoom: skip the <=1568px downscale (default false)"
499
509
  },
500
510
  action: {
501
511
  type: "string",
502
- description: "Action to perform: left_click | right_click | double_click | triple_click | left_click_drag | scroll | scroll_to | type | key | fill | fill_form | hover | wait | resize_page | zoom | screenshot"
512
+ description: "Action: left_click|right_click|double_click|triple_click|left_click_drag|scroll|scroll_to|type|key|fill|fill_form|hover|wait|resize_page|zoom|screenshot"
503
513
  },
504
514
  ref: {
505
515
  type: "string",
506
- description: "Element ref from chrome_read_page. For click/scroll/scroll_to/key/type and drag end when provided; takes precedence over coordinates."
516
+ description: "Element ref from chrome_read_page (click/scroll/key/type, drag end); beats coordinates."
507
517
  },
508
518
  coordinates: {
509
519
  type: "object",
510
520
  properties: {
511
- x: { type: "number", description: "X coordinate" },
512
- y: { type: "number", description: "Y coordinate" }
521
+ x: { type: "number" },
522
+ y: { type: "number" }
513
523
  },
514
- description: "Coordinates for actions (in screenshot space if a recent screenshot was taken, otherwise viewport). Required for click/scroll and as end point for drag."
524
+ description: "Screenshot-space if a recent screenshot exists, else viewport. Required for click/scroll and the drag end."
515
525
  },
516
526
  startCoordinates: {
517
527
  type: "object",
@@ -519,15 +529,15 @@ Tip: If the returned elements do not include the specific element you need, use
519
529
  x: { type: "number" },
520
530
  y: { type: "number" }
521
531
  },
522
- description: "Starting coordinates for drag action"
532
+ description: "Starting coordinates for drag."
523
533
  },
524
534
  startRef: {
525
535
  type: "string",
526
- description: "Drag start ref from chrome_read_page (alternative to startCoordinates)."
536
+ description: "Drag start ref (alternative to startCoordinates)."
527
537
  },
528
538
  scrollDirection: {
529
539
  type: "string",
530
- description: "Scroll direction: up | down | left | right"
540
+ description: "Scroll direction: up|down|left|right"
531
541
  },
532
542
  scrollAmount: {
533
543
  type: "number",
@@ -535,15 +545,15 @@ Tip: If the returned elements do not include the specific element you need, use
535
545
  },
536
546
  text: {
537
547
  type: "string",
538
- description: 'Text to type (for action=type) or keys/chords separated by space (for action=key, e.g. "Backspace Enter" or "cmd+a")'
548
+ description: 'Text to type (action=type), or space-separated keys/chords (action=key, e.g. "Backspace Enter", "cmd+a")'
539
549
  },
540
550
  repeat: {
541
551
  type: "number",
542
- description: "For action=key: number of times to repeat the key sequence (integer 1-100, default 1)."
552
+ description: "action=key: repeat (1-100, default 1)."
543
553
  },
544
554
  modifiers: {
545
555
  type: "object",
546
- description: "Modifier keys for click actions (left_click/right_click/double_click/triple_click).",
556
+ description: "Modifier keys for clicks.",
547
557
  properties: {
548
558
  altKey: { type: "boolean" },
549
559
  ctrlKey: { type: "boolean" },
@@ -553,7 +563,7 @@ Tip: If the returned elements do not include the specific element you need, use
553
563
  },
554
564
  region: {
555
565
  type: "object",
556
- description: "For action=zoom: rectangular region to capture (x0,y0)-(x1,y1) in viewport pixels (or screenshot-space if a recent screenshot context exists).",
566
+ description: "action=zoom: region (x0,y0)-(x1,y1) in viewport px (or screenshot-space if a recent screenshot exists).",
557
567
  properties: {
558
568
  x0: { type: "number" },
559
569
  y0: { type: "number" },
@@ -569,29 +579,29 @@ Tip: If the returned elements do not include the specific element you need, use
569
579
  },
570
580
  value: {
571
581
  oneOf: [{ type: "string" }, { type: "boolean" }, { type: "number" }],
572
- description: "Value to set for action=fill (string | boolean | number)"
582
+ description: "Value for action=fill (string|boolean|number)"
573
583
  },
574
584
  elements: {
575
585
  type: "array",
576
- description: "For action=fill_form: list of elements to fill (ref + value)",
586
+ description: "action=fill_form: elements to fill (ref + value)",
577
587
  items: {
578
588
  type: "object",
579
589
  properties: {
580
590
  ref: { type: "string", description: "Element ref from chrome_read_page" },
581
- value: { type: "string", description: "Value to set (stringified if non-string)" }
591
+ value: { type: "string", description: "Value to set (stringified if non-string)." }
582
592
  },
583
593
  required: ["ref", "value"]
584
594
  }
585
595
  },
586
- width: { type: "number", description: "For action=resize_page: viewport width" },
587
- height: { type: "number", description: "For action=resize_page: viewport height" },
596
+ width: { type: "number", description: "action=resize_page: viewport width" },
597
+ height: { type: "number", description: "action=resize_page: viewport height" },
588
598
  appear: {
589
599
  type: "boolean",
590
- description: "For action=wait with text: whether to wait for the text to appear (true, default) or disappear (false)"
600
+ description: "action=wait+text: appear (true, default) or disappear (false)"
591
601
  },
592
602
  timeout: {
593
603
  type: "number",
594
- description: "For action=wait with text: timeout in milliseconds (default 10000, max 120000)"
604
+ description: "action=wait+text: timeout in ms (default 10000, max 120000)"
595
605
  },
596
606
  duration: {
597
607
  type: "number",
@@ -601,133 +611,53 @@ Tip: If the returned elements do not include the specific element you need, use
601
611
  required: ["action"]
602
612
  }
603
613
  },
604
- // {
605
- // name: TOOL_NAMES.BROWSER.USERSCRIPT,
606
- // description:
607
- // 'Unified userscript tool (create/list/get/enable/disable/update/remove/send_command/export). Paste JS/CSS/Tampermonkey script and the system will auto-select the best strategy (insertCSS / persistent script in ISOLATED or MAIN world / once by CDP) with CSP-aware fallbacks.',
608
- // inputSchema: {
609
- // type: 'object',
610
- // properties: {
611
- // action: {
612
- // type: 'string',
613
- // description:
614
- // 'Operation to perform',
615
- // enum: [
616
- // 'create',
617
- // 'list',
618
- // 'get',
619
- // 'enable',
620
- // 'disable',
621
- // 'update',
622
- // 'remove',
623
- // 'send_command',
624
- // 'export',
625
- // ],
626
- // },
627
- // args: {
628
- // type: 'object',
629
- // description:
630
- // 'Arguments for the specified action.\n- create: { script (required), name?, description?, matches?: string[], excludes?: string[], persist?: boolean (default true), runAt?: "document_start"|"document_end"|"document_idle"|"auto", world?: "auto"|"ISOLATED"|"MAIN", allFrames?: boolean (default true), mode?: "auto"|"css"|"persistent"|"once", dnrFallback?: boolean (default true), tags?: string[] }\n- list: { query?: string, status?: "enabled"|"disabled", domain?: string }\n- get: { id (required) }\n- enable/disable: { id (required) }\n- update: { id (required), script?, name?, description?, matches?, excludes?, runAt?, world?, allFrames?, persist?, dnrFallback?, tags? }\n- remove: { id (required) }\n- send_command: { id (required), payload?: string, tabId?: number }\n- export: {}\nTip: For a one-off execution that returns a value, use create with args.mode="once". The returned value is included as onceResult in the tool response.',
631
- // properties: {
632
- // // Common identifiers
633
- // id: { type: 'string', description: 'Userscript id (for get/enable/disable/update/remove/send_command)' },
634
- // // Create / Update fields
635
- // script: { type: 'string', description: 'JS/CSS/Tampermonkey script source (required for create)' },
636
- // name: { type: 'string', description: 'Userscript name (optional)' },
637
- // description: { type: 'string', description: 'Userscript description (optional)' },
638
- // matches: {
639
- // type: 'array',
640
- // items: { type: 'string' },
641
- // description: 'Match patterns for pages to apply to (e.g., https://*.example.com/*)'
642
- // },
643
- // excludes: {
644
- // type: 'array',
645
- // items: { type: 'string' },
646
- // description: 'Exclude patterns'
647
- // },
648
- // persist: { type: 'boolean', description: 'Persist userscript for matched pages (default true)' },
649
- // runAt: {
650
- // type: 'string',
651
- // description: 'Injection timing',
652
- // enum: ['document_start', 'document_end', 'document_idle', 'auto'],
653
- // },
654
- // world: {
655
- // type: 'string',
656
- // description: 'Execution world',
657
- // enum: ['auto', 'ISOLATED', 'MAIN'],
658
- // },
659
- // allFrames: { type: 'boolean', description: 'Inject into all frames (default true)' },
660
- // mode: {
661
- // type: 'string',
662
- // description:
663
- // 'Injection strategy: auto | css | persistent | once. Use once to evaluate immediately (no persistence) and include the return value in onceResult.',
664
- // enum: ['auto', 'css', 'persistent', 'once'],
665
- // },
666
- // dnrFallback: { type: 'boolean', description: 'Use DNR fallback when needed (default true)' },
667
- // tags: { type: 'array', items: { type: 'string' }, description: 'Custom tags' },
668
- // // List filters
669
- // query: { type: 'string', description: 'Search by name/description (list action)' },
670
- // status: { type: 'string', enum: ['enabled', 'disabled'], description: 'Filter by status (list action)' },
671
- // domain: { type: 'string', description: 'Filter by domain (list action)' },
672
- // // Send command
673
- // payload: { type: 'string', description: 'Arbitrary payload (stringified) for send_command' },
674
- // tabId: { type: 'number', description: 'Target tab for send_command (default active tab)' },
675
- // },
676
- // },
677
- // },
678
- // required: ['action'],
679
- // },
680
- // },
681
614
  {
682
615
  name: TOOL_NAMES.BROWSER.NAVIGATE,
683
- description: "Navigate to a URL, refresh the current tab, or navigate browser history (back/forward)",
616
+ description: "Navigate to a URL, refresh the current tab, or go back/forward in history",
684
617
  inputSchema: {
685
618
  type: "object",
686
619
  properties: {
687
620
  url: {
688
621
  type: "string",
689
- description: 'URL to navigate to. Special values: "back" or "forward" to navigate browser history in the target tab.'
622
+ description: 'URL to navigate to. Special values "back"/"forward" navigate history in the target tab.'
690
623
  },
691
624
  newWindow: {
692
625
  type: "boolean",
693
- description: "Create a new window to navigate to the URL or not. Defaults to false"
626
+ description: "Create a new window for the URL (default false)."
694
627
  },
695
628
  waitUntil: {
696
629
  type: "string",
697
630
  enum: ["none", "domcontentloaded", "load", "networkidle"],
698
- description: 'How far to wait for the page to load before returning. Default "domcontentloaded" \u2014 prevents reading/clicking an empty page right after navigating. Use "networkidle" for data-heavy SPAs, "none" to return immediately. The observed load state is reported back in the result as "load" (a timeout is reported, not an error).'
631
+ description: 'How far to wait before returning. Default "domcontentloaded" (avoids reading an empty page); "networkidle" for data-heavy SPAs, "none" to return immediately. The observed load state is reported back (a timeout is reported, not an error).'
699
632
  },
700
633
  waitTimeoutMs: {
701
634
  type: "number",
702
- description: "Max time (ms) to wait for waitUntil. Default 15000, max 60000."
635
+ description: "Max wait for waitUntil (default 15000, max 60000)."
703
636
  },
704
637
  tabId: {
705
638
  type: "number",
706
- description: "Target an existing tab by ID (if provided, navigate/refresh/back/forward that tab instead of the active tab)."
639
+ description: "Navigate/refresh/back/forward this existing tab instead of the active tab."
707
640
  },
708
641
  windowId: {
709
642
  type: "number",
710
- description: "Target an existing window by ID (when creating a new tab in existing window, or picking active tab if tabId is not provided)."
711
- },
712
- background: {
713
- type: "boolean",
714
- description: "Perform the operation without stealing focus (do not activate the tab or focus the window). Default: false"
643
+ description: "Existing window for a new tab, or to pick the active tab when tabId is omitted."
715
644
  },
645
+ background: backgroundProp,
716
646
  newTab: {
717
647
  type: "boolean",
718
- description: "Force a brand-new tab. By default this session keeps working in ONE tab: if it already has an MCP-created work tab, that tab is navigated instead of piling up new tabs. Tabs you assigned yourself via chrome_set_work_tab are never reused this way."
648
+ description: "Force a brand-new tab. By default the session works in ONE tab: an existing MCP work tab is navigated instead of piling up tabs. Tabs set via chrome_set_work_tab are never reused this way."
719
649
  },
720
650
  width: {
721
651
  type: "number",
722
- description: "Window width in pixels (default: 1280). When width or height is provided, a new window will be created."
652
+ description: "Window width px (default 1280). Providing width or height creates a new window."
723
653
  },
724
654
  height: {
725
655
  type: "number",
726
- description: "Window height in pixels (default: 720). When width or height is provided, a new window will be created."
656
+ description: "Window height px (default 720). Providing width or height creates a new window."
727
657
  },
728
658
  refresh: {
729
659
  type: "boolean",
730
- description: "Refresh the current active tab instead of navigating to a URL. When true, the url parameter is ignored. Defaults to false"
660
+ description: "Refresh the active tab instead of navigating (url ignored). Default false."
731
661
  }
732
662
  },
733
663
  required: []
@@ -735,7 +665,7 @@ Tip: If the returned elements do not include the specific element you need, use
735
665
  },
736
666
  {
737
667
  name: TOOL_NAMES.BROWSER.SCREENSHOT,
738
- description: '[Prefer read_page over taking a screenshot and Prefer chrome_computer] Take a screenshot of the current page or a specific element. For new usage, use chrome_computer with action="screenshot". Use this tool if you need advanced options.',
668
+ description: '[Prefer chrome_read_page, or chrome_computer action="screenshot"] Take a screenshot of the page or an element. Use this tool only when you need its advanced options.',
739
669
  inputSchema: {
740
670
  type: "object",
741
671
  properties: {
@@ -747,21 +677,21 @@ Tip: If the returned elements do not include the specific element you need, use
747
677
  },
748
678
  windowId: {
749
679
  type: "number",
750
- description: "Target window ID to pick active tab from when tabId is not provided."
680
+ description: "Target window ID to pick active tab when tabId is not provided."
751
681
  },
752
682
  background: {
753
683
  type: "boolean",
754
- description: "Attempt capture without bringing tab/window to foreground. CDP-based capture is used for simple viewport captures. For element/full-page capture, the tab may still be made active in its window without focusing the window. Default: false"
684
+ description: "Capture without bringing the tab/window to the foreground. For element/full-page capture the tab may still be activated in its window without focusing it. Default: false"
755
685
  },
756
686
  width: { type: "number", description: "Width in pixels (default: 800)" },
757
687
  height: { type: "number", description: "Height in pixels (default: 600)" },
758
688
  storeBase64: {
759
689
  type: "boolean",
760
- description: "Return the screenshot as an MCP image content block (default: false). Recommended when you want to SEE the page. The image is auto-downscaled to \u22641568px long edge (metadata reports imageScale vs the CSS viewport for coordinate math); pass fullResolution:true to skip downscaling."
690
+ description: "Return the image as an MCP image content block (default: false). Auto-downscaled to <=1568px long edge (metadata reports imageScale); pass fullResolution:true to skip."
761
691
  },
762
692
  fullResolution: {
763
693
  type: "boolean",
764
- description: "Skip the \u22641568px downscale for the returned image (default: false)"
694
+ description: "Skip the <=1568px downscale for the returned image (default: false)"
765
695
  },
766
696
  fullPage: {
767
697
  type: "boolean",
@@ -769,15 +699,15 @@ Tip: If the returned elements do not include the specific element you need, use
769
699
  },
770
700
  savePng: {
771
701
  type: "boolean",
772
- description: "Save screenshot as PNG file (default: true)\uFF0Cif you want to see the page, recommend set this to be false, and set storeBase64 to be true"
702
+ description: "Save as a PNG file (default: true). To see the page, set false and storeBase64 true."
773
703
  },
774
704
  saveToDownloads: {
775
705
  type: "boolean",
776
- description: "Also auto-save the captured image to Downloads/mcp-screenshots/ without any user interaction (default: false)"
706
+ description: "Also auto-save to Downloads/mcp-screenshots/ (default: false)"
777
707
  },
778
708
  filename: {
779
709
  type: "string",
780
- description: "Filename for saveToDownloads (sanitized, kept under mcp-screenshots/). Default: screenshot-<timestamp>.png"
710
+ description: "Filename for saveToDownloads (sanitized, under mcp-screenshots/)."
781
711
  }
782
712
  },
783
713
  required: []
@@ -792,7 +722,7 @@ Tip: If the returned elements do not include the specific element you need, use
792
722
  tabIds: {
793
723
  type: "array",
794
724
  items: { type: "number" },
795
- description: "Array of tab IDs to close. If not provided, will close the active tab."
725
+ description: "Tab IDs to close. If not provided, closes the active tab."
796
726
  },
797
727
  url: {
798
728
  type: "string",
@@ -804,7 +734,7 @@ Tip: If the returned elements do not include the specific element you need, use
804
734
  },
805
735
  {
806
736
  name: TOOL_NAMES.BROWSER.SWITCH_TAB,
807
- description: "Bring a tab to the front (activates it and can take OS focus). Use ONLY when the user explicitly asked to switch/show a tab. To retarget automation at another tab without disturbing the user, use chrome_set_work_tab instead - this tool is exempt from the no-interference gate, so it will actually change what the user is looking at.",
737
+ description: "Bring a tab to the front (activates it and can take OS focus). Use ONLY when the user explicitly asked to switch/show a tab. To retarget automation without disturbing the user, use chrome_set_work_tab; this tool is exempt from the no-interference gate, so it changes what the user sees.",
808
738
  inputSchema: {
809
739
  type: "object",
810
740
  properties: {
@@ -822,45 +752,42 @@ Tip: If the returned elements do not include the specific element you need, use
822
752
  },
823
753
  {
824
754
  name: TOOL_NAMES.BROWSER.WEB_FETCHER,
825
- description: "Read a page as text (reader view by default: nav/footer/cookie-banner noise stripped) or as cleaned HTML. Repeat reads of an unchanged tab return {unchanged:true} instead of the body. Both modes are length-capped and report fullTextChars/fullHtmlChars vs returnedChars so you can tell what was cut. For a handful of known fields prefer chrome_extract, and for clicking/typing prefer chrome_read_page (it returns element refs); use this when you want the page content itself.",
755
+ description: "Read a page as text (reader view by default: nav/footer/cookie-banner noise stripped) or cleaned HTML. Repeat reads of an unchanged tab return {unchanged:true}; both modes are length-capped (report fullTextChars/fullHtmlChars vs returnedChars). For known fields prefer chrome_extract; for clicking/typing prefer chrome_read_page (returns refs); use this for the page content itself.",
826
756
  inputSchema: {
827
757
  type: "object",
828
758
  properties: {
829
759
  url: {
830
760
  type: "string",
831
- description: "URL to fetch content from. If not provided, uses the current active tab"
761
+ description: "URL to fetch. If not provided, uses the current active tab"
832
762
  },
833
763
  tabId: {
834
764
  type: "number",
835
765
  description: "Target an existing tab by ID (default: active tab)."
836
766
  },
837
- background: {
838
- type: "boolean",
839
- description: "Do not activate tab/focus window while fetching (default: false)"
840
- },
767
+ background: backgroundProp,
841
768
  htmlContent: {
842
769
  type: "boolean",
843
- description: "Return cleaned HTML (scripts/styles/SVG stripped) instead of text. Much more expensive than text \u2014 use it only when you need markup/attributes, and pair it with selector. If true, textContent is ignored (default: false)"
770
+ description: "Return cleaned HTML (scripts/styles/SVG stripped) instead of text. Much more expensive; use only for markup/attributes and pair with selector. If true, textContent is ignored (default: false)"
844
771
  },
845
772
  textContent: {
846
773
  type: "boolean",
847
- description: "Get the visible text content of the page with metadata. Ignored if htmlContent is true (default: true)"
774
+ description: "Visible text with metadata. Ignored if htmlContent is true (default true)"
848
775
  },
849
776
  selector: {
850
777
  type: "string",
851
- description: "CSS selector to get content from a specific element. If provided, only content from this element will be returned"
778
+ description: "CSS selector to return content from a specific element only."
852
779
  },
853
780
  maxChars: {
854
781
  type: "number",
855
- description: "Cap on returned HTML length (default 100000). Only applies to htmlContent mode; the result reports fullHtmlChars/returnedChars and truncated:true when it was cut."
782
+ description: "Cap on returned HTML length (default 100000, htmlContent mode only); reports truncated:true when cut."
856
783
  },
857
784
  raw: {
858
785
  type: "boolean",
859
- description: "Text mode returns reader-view content by default (navigation/footer/cookie-banner noise stripped, main content kept \u2014 fullTextChars vs returnedChars reported). Pass true for the unfiltered full text. Default: false"
786
+ description: "Text mode: reader-view by default (noise stripped); true = unfiltered full text. Default false"
860
787
  },
861
788
  diff: {
862
789
  type: "boolean",
863
- description: "When true (default), returns {unchanged:true} instead of the body if identical to your previous read of this tab (text and HTML modes are tracked separately) \u2014 reuse the earlier content. Pass false to force full re-send."
790
+ description: "When true (default), returns {unchanged:true} if identical to your last read (text/HTML tracked separately); false forces re-send."
864
791
  }
865
792
  },
866
793
  required: []
@@ -894,11 +821,11 @@ Tip: If the returned elements do not include the specific element you need, use
894
821
  },
895
822
  formData: {
896
823
  type: "object",
897
- description: "Multipart/form-data descriptor. If provided, overrides body and builds FormData with optional file attachments. Shape: { fields?: Record<string,string|number|boolean>, files?: Array<{ name: string, fileUrl?: string, filePath?: string, base64Data?: string, filename?: string, contentType?: string }> }. Also supports a compact array form: [ [name, fileSpec, filename?], ... ] where fileSpec may be url:, file:, or base64:."
824
+ description: "Multipart/form-data descriptor. Overrides body and builds FormData with optional file attachments. Shape: { fields?: Record<string,string|number|boolean>, files?: Array<{ name, fileUrl?, filePath?, base64Data?, filename?, contentType? }> }. Also a compact array form: [ [name, fileSpec, filename?], ... ] where fileSpec is url:, file:, or base64:."
898
825
  },
899
826
  tabId: {
900
827
  type: "number",
901
- description: "Optional tab id whose browser context (cookies, origin) is used. Defaults to the MCP work tab (background work mode) or the active tab."
828
+ description: "Tab id whose browser context (cookies, origin) is used. Omit to use this session's work tab."
902
829
  }
903
830
  },
904
831
  required: ["url"]
@@ -906,42 +833,39 @@ Tip: If the returned elements do not include the specific element you need, use
906
833
  },
907
834
  {
908
835
  name: TOOL_NAMES.BROWSER.NETWORK_CAPTURE,
909
- description: 'Unified network capture tool. Use action="start" to begin capturing, action="stop" to end and retrieve results. Set needResponseBody=true to capture response bodies (uses Debugger API, may conflict with DevTools). Default mode uses webRequest API (lightweight, no debugger conflict, but no response body).',
836
+ description: 'Unified network capture. action="start" begins, action="stop" ends and returns results. needResponseBody=true captures response bodies (Debugger API, may conflict with DevTools); the default webRequest mode is lightweight but has no response body.',
910
837
  inputSchema: {
911
838
  type: "object",
912
839
  properties: {
913
840
  action: {
914
841
  type: "string",
915
842
  enum: ["start", "stop"],
916
- description: 'Action to perform: "start" begins capture, "stop" ends and returns results'
843
+ description: '"start" begins capture, "stop" ends and returns results'
917
844
  },
918
845
  needResponseBody: {
919
846
  type: "boolean",
920
- description: "When true, captures response body using Debugger API (default: false). Only use when you need to inspect response content."
847
+ description: "Capture response bodies via the Debugger API (default: false)."
921
848
  },
922
849
  url: {
923
850
  type: "string",
924
- description: 'URL to capture network requests from. For action="start". If not provided, uses the current active tab.'
851
+ description: 'action="start": URL to capture from. If omitted, uses the current active tab.'
925
852
  },
926
853
  maxCaptureTime: {
927
854
  type: "number",
928
- description: "Maximum capture time in milliseconds (default: 180000)"
855
+ description: "Maximum capture time in ms (default: 180000)"
929
856
  },
930
857
  inactivityTimeout: {
931
858
  type: "number",
932
- description: "Stop after inactivity in milliseconds (default: 60000). Set 0 to disable."
859
+ description: "Stop after inactivity in ms (default: 60000). Set 0 to disable."
933
860
  },
934
861
  includeStatic: {
935
862
  type: "boolean",
936
863
  description: "Include static resources like images/scripts/styles (default: false)"
937
864
  },
938
- tabId: {
939
- type: "number",
940
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
941
- },
865
+ tabId: tabIdProp,
942
866
  limit: {
943
867
  type: "number",
944
- description: 'action="stop": return at most this many captured requests (default 100; paginate with offset)'
868
+ description: 'action="stop": max requests to return (default 100; paginate with offset)'
945
869
  },
946
870
  offset: {
947
871
  type: "number",
@@ -949,7 +873,7 @@ Tip: If the returned elements do not include the specific element you need, use
949
873
  },
950
874
  countOnly: {
951
875
  type: "boolean",
952
- description: 'action="stop": return only counts/summary without the request array (default: false)'
876
+ description: 'action="stop": counts/summary only, no request array (default false)'
953
877
  }
954
878
  },
955
879
  required: ["action"]
@@ -976,23 +900,23 @@ Tip: If the returned elements do not include the specific element you need, use
976
900
  properties: {
977
901
  text: {
978
902
  type: "string",
979
- description: "Text to search for in history URLs and titles. Leave empty to retrieve all history entries within the time range."
903
+ description: "Text to search in history URLs/titles. Empty = all entries in the time range."
980
904
  },
981
905
  startTime: {
982
906
  type: "string",
983
- description: 'Start time as a date string. Supports ISO format (e.g., "2023-10-01", "2023-10-01T14:30:00"), relative times (e.g., "1 day ago", "2 weeks ago", "3 months ago", "1 year ago"), and special keywords ("now", "today", "yesterday"). Default: 24 hours ago'
907
+ description: 'Start time: ISO, relative ("1 day ago"), or keyword ("now"/"today"/"yesterday"). Default: 24 hours ago'
984
908
  },
985
909
  endTime: {
986
910
  type: "string",
987
- description: 'End time as a date string. Supports ISO format (e.g., "2023-10-31", "2023-10-31T14:30:00"), relative times (e.g., "1 day ago", "2 weeks ago", "3 months ago", "1 year ago"), and special keywords ("now", "today", "yesterday"). Default: current time'
911
+ description: 'End time: ISO, relative, or keyword ("now"/"today"/"yesterday"). Default: now'
988
912
  },
989
913
  maxResults: {
990
914
  type: "number",
991
- description: "Maximum number of history entries to return. Use this to limit results for performance or to focus on the most relevant entries. (default: 100)"
915
+ description: "Max history entries to return (default: 100)"
992
916
  },
993
917
  excludeCurrentTabs: {
994
918
  type: "boolean",
995
- description: "When set to true, filters out URLs that are currently open in any browser tab. Useful for finding pages you've visited but don't have open anymore. (default: false)"
919
+ description: "When true, exclude URLs currently open in any tab. Default false"
996
920
  },
997
921
  limit: {
998
922
  type: "number",
@@ -1018,15 +942,15 @@ Tip: If the returned elements do not include the specific element you need, use
1018
942
  properties: {
1019
943
  query: {
1020
944
  type: "string",
1021
- description: "Search query to match against bookmark titles and URLs. Leave empty to retrieve all bookmarks."
945
+ description: "Query matched against bookmark titles and URLs. Empty = all bookmarks."
1022
946
  },
1023
947
  maxResults: {
1024
948
  type: "number",
1025
- description: "Maximum number of bookmarks to return (default: 50)"
949
+ description: "Max bookmarks to return (default: 50)"
1026
950
  },
1027
951
  folderPath: {
1028
952
  type: "string",
1029
- description: 'Optional folder path or ID to limit search to a specific bookmark folder. Can be a path string (e.g., "Work/Projects") or a folder ID.'
953
+ description: 'Limit to a folder: a path string (e.g. "Work/Projects") or a folder ID.'
1030
954
  }
1031
955
  },
1032
956
  required: []
@@ -1044,19 +968,19 @@ Tip: If the returned elements do not include the specific element you need, use
1044
968
  },
1045
969
  title: {
1046
970
  type: "string",
1047
- description: "Title for the bookmark. If not provided, uses the page title from the URL."
971
+ description: "Title. If not provided, uses the page title."
1048
972
  },
1049
973
  parentId: {
1050
974
  type: "string",
1051
- description: 'Parent folder path or ID to add the bookmark to. Can be a path string (e.g., "Work/Projects") or a folder ID. If not provided, adds to the "Bookmarks Bar" folder.'
975
+ description: 'Parent folder: path (e.g. "Work/Projects") or folder ID. Default: "Bookmarks Bar".'
1052
976
  },
1053
977
  createFolder: {
1054
978
  type: "boolean",
1055
- description: "Whether to create the parent folder if it does not exist (default: false)"
979
+ description: "Create the parent folder if missing (default: false)"
1056
980
  },
1057
981
  tabId: {
1058
982
  type: "number",
1059
- description: "Optional tab id to bookmark when url is omitted. Defaults to the MCP work tab (background work mode) or the active tab."
983
+ description: "Tab id to bookmark when url is omitted. Omit to use this session's work tab."
1060
984
  }
1061
985
  },
1062
986
  required: []
@@ -1070,7 +994,7 @@ Tip: If the returned elements do not include the specific element you need, use
1070
994
  properties: {
1071
995
  bookmarkId: {
1072
996
  type: "string",
1073
- description: "ID of the bookmark to delete. Either bookmarkId or url must be provided."
997
+ description: "ID of the bookmark to delete. Either bookmarkId or url is required."
1074
998
  },
1075
999
  url: {
1076
1000
  type: "string",
@@ -1078,112 +1002,33 @@ Tip: If the returned elements do not include the specific element you need, use
1078
1002
  },
1079
1003
  title: {
1080
1004
  type: "string",
1081
- description: "Title of the bookmark to help with matching when deleting by URL."
1005
+ description: "Title to help match when deleting by URL."
1082
1006
  }
1083
1007
  },
1084
1008
  required: []
1085
1009
  }
1086
1010
  },
1087
- // {
1088
- // name: TOOL_NAMES.BROWSER.SEARCH_TABS_CONTENT,
1089
- // description:
1090
- // 'search for related content from the currently open tab and return the corresponding web pages.',
1091
- // inputSchema: {
1092
- // type: 'object',
1093
- // properties: {
1094
- // query: {
1095
- // type: 'string',
1096
- // description: 'the query to search for related content.',
1097
- // },
1098
- // },
1099
- // required: ['query'],
1100
- // },
1101
- // },
1102
- // {
1103
- // name: TOOL_NAMES.BROWSER.INJECT_SCRIPT,
1104
- // description:
1105
- // 'inject the user-specified content script into the webpage. By default, inject into the currently active tab',
1106
- // inputSchema: {
1107
- // type: 'object',
1108
- // properties: {
1109
- // url: {
1110
- // type: 'string',
1111
- // description:
1112
- // 'If a URL is specified, inject the script into the webpage corresponding to the URL.',
1113
- // },
1114
- // tabId: {
1115
- // type: 'number',
1116
- // description:
1117
- // 'Target an existing tab by ID to inject into. Overrides url/active tab selection when provided.',
1118
- // },
1119
- // windowId: {
1120
- // type: 'number',
1121
- // description:
1122
- // 'Target window ID for selecting active tab or creating new tab when url is provided and tabId is omitted.',
1123
- // },
1124
- // background: {
1125
- // type: 'boolean',
1126
- // description:
1127
- // 'Do not activate tab/focus window during injection when true (default: false).',
1128
- // },
1129
- // type: {
1130
- // type: 'string',
1131
- // description:
1132
- // 'the javaScript world for a script to execute within. must be ISOLATED or MAIN',
1133
- // },
1134
- // jsScript: {
1135
- // type: 'string',
1136
- // description: 'the content script to inject',
1137
- // },
1138
- // },
1139
- // required: ['type', 'jsScript'],
1140
- // },
1141
- // },
1142
- // {
1143
- // name: TOOL_NAMES.BROWSER.SEND_COMMAND_TO_INJECT_SCRIPT,
1144
- // description:
1145
- // 'if the script injected using chrome_inject_script listens for user-defined events, this tool can be used to trigger those events',
1146
- // inputSchema: {
1147
- // type: 'object',
1148
- // properties: {
1149
- // tabId: {
1150
- // type: 'number',
1151
- // description:
1152
- // 'the tab where you previously injected the script(if not provided, use the currently active tab)',
1153
- // },
1154
- // eventName: {
1155
- // type: 'string',
1156
- // description: 'the eventName your injected content script listen for',
1157
- // },
1158
- // payload: {
1159
- // type: 'string',
1160
- // description: 'the payload passed to event, must be a json string',
1161
- // },
1162
- // },
1163
- // required: ['eventName'],
1164
- // },
1165
- // },
1166
1011
  {
1167
1012
  name: TOOL_NAMES.BROWSER.JAVASCRIPT,
1168
- description: "Execute JavaScript code in a browser tab and return the result. Uses CDP Runtime.evaluate with awaitPromise and returnByValue; automatically falls back to chrome.scripting.executeScript if the debugger is busy. Output is sanitized (sensitive data redacted) and truncated by default.",
1013
+ description: "Execute JavaScript in a tab and return the result. Uses CDP Runtime.evaluate (awaitPromise, returnByValue) and falls back to chrome.scripting.executeScript if the debugger is busy. Output is sanitized (sensitive data redacted) and truncated by default.",
1169
1014
  inputSchema: {
1170
1015
  type: "object",
1171
1016
  properties: {
1172
1017
  code: {
1173
1018
  type: "string",
1174
- description: 'JavaScript code to execute. Runs inside an async function body, so top-level await and "return ..." are supported.'
1019
+ description: 'JavaScript to run (async function body; top-level await and "return ..." supported).'
1175
1020
  },
1176
1021
  tabId: {
1177
1022
  type: "number",
1178
- description: "Target tab ID. If omitted, uses the current active tab."
1023
+ description: "Target tab id. Omit to use this session's work tab."
1179
1024
  },
1180
1025
  timeoutMs: {
1181
1026
  type: "number",
1182
- description: "Execution timeout in milliseconds (default: 15000)."
1027
+ description: "Execution timeout in ms (default: 15000)."
1183
1028
  },
1184
1029
  maxOutputBytes: {
1185
1030
  type: "number",
1186
- description: "Maximum output size in bytes after sanitization (default: 51200). Output exceeding this limit will be truncated."
1031
+ description: "Max output bytes after sanitization (default 51200); excess truncated."
1187
1032
  }
1188
1033
  },
1189
1034
  required: ["code"]
@@ -1191,7 +1036,7 @@ Tip: If the returned elements do not include the specific element you need, use
1191
1036
  },
1192
1037
  {
1193
1038
  name: TOOL_NAMES.BROWSER.CLICK,
1194
- description: 'Click on an element in a web page. Supports multiple targeting methods: CSS selector, XPath, element ref (from chrome_read_page), or viewport coordinates. More focused than chrome_computer for simple click operations. Waits briefly for the element by default (waitForElementMs). When the click is blocked or the element is covered, the result carries an "obstruction" object naming the element/overlay on top of the target \u2014 read it instead of retrying the same click.',
1039
+ description: 'Click an element by CSS selector, XPath, element ref (from chrome_read_page), or viewport coordinates. More focused than chrome_computer for simple clicks; waits briefly (waitForElementMs). If blocked/covered, the result carries an "obstruction" object naming the overlay on top; read it instead of retrying.',
1195
1040
  inputSchema: {
1196
1041
  type: "object",
1197
1042
  properties: {
@@ -1199,15 +1044,8 @@ Tip: If the returned elements do not include the specific element you need, use
1199
1044
  type: "string",
1200
1045
  description: "CSS selector or XPath for the element to click."
1201
1046
  },
1202
- waitForElementMs: {
1203
- type: "number",
1204
- description: 'How long (ms) to wait for the target element to appear and become visible before failing. Default 2000; set 0 to fail immediately. Removes the usual "click failed -> chrome_wait_for -> click again" round-trip on SPA/lazy-rendered pages.'
1205
- },
1206
- selectorType: {
1207
- type: "string",
1208
- enum: ["css", "xpath"],
1209
- description: 'Type of selector (default: "css").'
1210
- },
1047
+ waitForElementMs: waitForElementMsProp,
1048
+ selectorType: selectorTypeProp,
1211
1049
  ref: {
1212
1050
  type: "string",
1213
1051
  description: "Element ref from chrome_read_page (takes precedence over selector)."
@@ -1223,12 +1061,12 @@ Tip: If the returned elements do not include the specific element you need, use
1223
1061
  },
1224
1062
  double: {
1225
1063
  type: "boolean",
1226
- description: "Perform double click when true (default: false)."
1064
+ description: "Double click when true (default: false)."
1227
1065
  },
1228
1066
  button: {
1229
1067
  type: "string",
1230
1068
  enum: ["left", "right", "middle"],
1231
- description: 'Mouse button to click (default: "left").'
1069
+ description: 'Mouse button (default: "left").'
1232
1070
  },
1233
1071
  modifiers: {
1234
1072
  type: "object",
@@ -1242,31 +1080,25 @@ Tip: If the returned elements do not include the specific element you need, use
1242
1080
  },
1243
1081
  waitForNavigation: {
1244
1082
  type: "boolean",
1245
- description: "Wait for navigation to complete after click (default: false)."
1083
+ description: "Wait for navigation after click (default: false)."
1246
1084
  },
1247
1085
  timeout: {
1248
1086
  type: "number",
1249
- description: "Timeout in milliseconds for waiting (default: 5000)."
1087
+ description: "Timeout in ms for waiting (default: 5000)."
1250
1088
  },
1251
1089
  tabId: {
1252
1090
  type: "number",
1253
- description: "Target tab ID. If omitted, uses the current active tab."
1254
- },
1255
- windowId: {
1256
- type: "number",
1257
- description: "Window ID to select active tab from (when tabId is omitted)."
1091
+ description: "Target tab id. Omit to use this session's work tab."
1258
1092
  },
1259
- frameId: {
1260
- type: "number",
1261
- description: "Target frame ID for iframe support."
1262
- }
1093
+ windowId: windowIdProp,
1094
+ frameId: frameIdProp
1263
1095
  },
1264
1096
  required: []
1265
1097
  }
1266
1098
  },
1267
1099
  {
1268
1100
  name: TOOL_NAMES.BROWSER.FILL,
1269
- description: "Fill or select a form element on a web page. Supports input, textarea, select, checkbox, radio, and contenteditable elements (the prompt boxes used by modern editors such as Google Flow, Gemini, ChatGPT and Notion). Use CSS selector, XPath, or element ref to target the element.",
1101
+ description: "Fill or select a form element. Supports input, textarea, select, checkbox, radio, and contenteditable (editor prompt boxes like Google Flow, Gemini, ChatGPT, Notion). Target by CSS selector, XPath, or element ref.",
1270
1102
  inputSchema: {
1271
1103
  type: "object",
1272
1104
  properties: {
@@ -1274,63 +1106,50 @@ Tip: If the returned elements do not include the specific element you need, use
1274
1106
  type: "string",
1275
1107
  description: "CSS selector or XPath for the form element."
1276
1108
  },
1277
- waitForElementMs: {
1278
- type: "number",
1279
- description: 'How long (ms) to wait for the target element to appear and become visible before failing. Default 2000; set 0 to fail immediately. Removes the usual "click failed -> chrome_wait_for -> click again" round-trip on SPA/lazy-rendered pages.'
1280
- },
1281
- selectorType: {
1282
- type: "string",
1283
- enum: ["css", "xpath"],
1284
- description: 'Type of selector (default: "css").'
1285
- },
1109
+ waitForElementMs: waitForElementMsProp,
1110
+ selectorType: selectorTypeProp,
1286
1111
  ref: {
1287
1112
  type: "string",
1288
1113
  description: "Element ref from chrome_read_page (takes precedence over selector)."
1289
1114
  },
1290
1115
  value: {
1291
1116
  type: ["string", "number", "boolean"],
1292
- description: "Value to fill. For text inputs: string. For checkboxes/radios: boolean. For selects: option value or text."
1117
+ description: "Value: string (text), boolean (checkbox/radio), or option value/text (select)."
1293
1118
  },
1294
1119
  tabId: {
1295
1120
  type: "number",
1296
- description: "Target tab ID. If omitted, uses the current active tab."
1297
- },
1298
- windowId: {
1299
- type: "number",
1300
- description: "Window ID to select active tab from (when tabId is omitted)."
1121
+ description: "Target tab id. Omit to use this session's work tab."
1301
1122
  },
1302
- frameId: {
1303
- type: "number",
1304
- description: "Target frame ID for iframe support."
1305
- }
1123
+ windowId: windowIdProp,
1124
+ frameId: frameIdProp
1306
1125
  },
1307
1126
  required: ["value"]
1308
1127
  }
1309
1128
  },
1310
1129
  {
1311
1130
  name: TOOL_NAMES.BROWSER.REQUEST_ELEMENT_SELECTION,
1312
- description: "Request the user to manually select one or more elements on the current page. Use this as a human-in-the-loop fallback when you cannot reliably locate the target element after approximately 3 attempts using chrome_read_page combined with chrome_click_element/chrome_fill_or_select/chrome_computer. The user will see a panel with instructions and can click on the requested elements. Returns element refs compatible with chrome_click_element/chrome_fill_or_select (including iframe frameId for cross-frame support).",
1131
+ description: "Ask the user to manually select elements on the page. A human-in-the-loop fallback when you cannot locate the target after ~3 attempts with chrome_read_page + click/fill/computer. Returns element refs for chrome_click_element/chrome_fill_or_select (including iframe frameId).",
1313
1132
  inputSchema: {
1314
1133
  type: "object",
1315
1134
  properties: {
1316
1135
  requests: {
1317
1136
  type: "array",
1318
- description: "A list of element selection requests. Each request produces exactly one picked element. The user will see these requests in a panel and select each element by clicking on the page.",
1137
+ description: "Selection requests; each yields one picked element the user clicks on the page.",
1319
1138
  minItems: 1,
1320
1139
  items: {
1321
1140
  type: "object",
1322
1141
  properties: {
1323
1142
  id: {
1324
1143
  type: "string",
1325
- description: 'Optional stable request id for correlation. If omitted, an id is auto-generated (e.g., "req_1").'
1144
+ description: "Stable request id for correlation. Auto-generated if omitted."
1326
1145
  },
1327
1146
  name: {
1328
1147
  type: "string",
1329
- description: 'Short label shown to the user describing what element to select (e.g., "Login button", "Email input field").'
1148
+ description: 'Short label shown to the user (e.g. "Login button").'
1330
1149
  },
1331
1150
  description: {
1332
1151
  type: "string",
1333
- description: 'Optional longer instruction shown to the user with more context (e.g., "Click on the primary login button in the top-right corner").'
1152
+ description: "Optional longer instruction shown to the user."
1334
1153
  }
1335
1154
  },
1336
1155
  required: ["name"]
@@ -1338,68 +1157,55 @@ Tip: If the returned elements do not include the specific element you need, use
1338
1157
  },
1339
1158
  timeoutMs: {
1340
1159
  type: "number",
1341
- description: "Timeout in milliseconds for the user to complete all selections. Default: 180000 (3 minutes). Maximum: 600000 (10 minutes)."
1160
+ description: "Timeout ms for the user to finish (default 180000, max 600000)."
1342
1161
  },
1343
1162
  tabId: {
1344
1163
  type: "number",
1345
- description: "Target tab ID. If omitted, uses the current active tab."
1164
+ description: "Target tab id. Omit to use this session's work tab."
1346
1165
  },
1347
- windowId: {
1348
- type: "number",
1349
- description: "Window ID to select active tab from (when tabId is omitted)."
1350
- }
1166
+ windowId: windowIdProp
1351
1167
  },
1352
1168
  required: ["requests"]
1353
1169
  }
1354
1170
  },
1355
1171
  {
1356
1172
  name: TOOL_NAMES.BROWSER.KEYBOARD,
1357
- description: "Simulate keyboard input on a web page. Supports single keys (Enter, Tab, Escape), key combinations (Ctrl+C, Ctrl+V), and text input. Can target a specific element or send to the focused element.",
1173
+ description: "Simulate keyboard input: single keys (Enter, Tab, Escape), combinations (Ctrl+C, Ctrl+V), and text. Can target a specific element or send to the focused element.",
1358
1174
  inputSchema: {
1359
1175
  type: "object",
1360
1176
  properties: {
1361
1177
  keys: {
1362
1178
  type: "string",
1363
- description: 'Keys or key combinations to simulate. Examples: "Enter", "Tab", "Ctrl+C", "Shift+Tab", "Hello World".'
1179
+ description: 'Keys or combinations, e.g. "Enter", "Tab", "Ctrl+C", "Shift+Tab", "Hello World".'
1364
1180
  },
1365
1181
  selector: {
1366
1182
  type: "string",
1367
- description: "CSS selector or XPath for target element to receive keyboard events."
1368
- },
1369
- selectorType: {
1370
- type: "string",
1371
- enum: ["css", "xpath"],
1372
- description: 'Type of selector (default: "css").'
1183
+ description: "CSS selector or XPath for the element to receive keyboard events."
1373
1184
  },
1185
+ selectorType: selectorTypeProp,
1374
1186
  delay: {
1375
1187
  type: "number",
1376
- description: "Delay between keystrokes in milliseconds (default: 50)."
1188
+ description: "Delay between keystrokes in ms (default: 50)."
1377
1189
  },
1378
1190
  tabId: {
1379
1191
  type: "number",
1380
- description: "Target tab ID. If omitted, uses the current active tab."
1381
- },
1382
- windowId: {
1383
- type: "number",
1384
- description: "Window ID to select active tab from (when tabId is omitted)."
1192
+ description: "Target tab id. Omit to use this session's work tab."
1385
1193
  },
1386
- frameId: {
1387
- type: "number",
1388
- description: "Target frame ID for iframe support."
1389
- }
1194
+ windowId: windowIdProp,
1195
+ frameId: frameIdProp
1390
1196
  },
1391
1197
  required: ["keys"]
1392
1198
  }
1393
1199
  },
1394
1200
  {
1395
1201
  name: TOOL_NAMES.BROWSER.CONSOLE,
1396
- description: "Capture console output from a browser tab. Supports snapshot mode (default; one-time capture with ~2s wait) and buffer mode (persistent per-tab buffer you can read/clear instantly without waiting).",
1202
+ description: "Capture console output from a tab. Snapshot mode (default) does a one-time capture with a ~2s wait; buffer mode keeps a persistent per-tab buffer you can read/clear instantly.",
1397
1203
  inputSchema: {
1398
1204
  type: "object",
1399
1205
  properties: {
1400
1206
  url: {
1401
1207
  type: "string",
1402
- description: "URL to navigate to and capture console from. If not provided, uses the current active tab"
1208
+ description: "URL to navigate to and capture from. If omitted, uses the current active tab"
1403
1209
  },
1404
1210
  tabId: {
1405
1211
  type: "number",
@@ -1415,15 +1221,15 @@ Tip: If the returned elements do not include the specific element you need, use
1415
1221
  },
1416
1222
  includeExceptions: {
1417
1223
  type: "boolean",
1418
- description: "Include uncaught exceptions in the output (default: true)"
1224
+ description: "Include uncaught exceptions (default: true)"
1419
1225
  },
1420
1226
  maxMessages: {
1421
1227
  type: "number",
1422
- description: "Maximum number of console messages to capture in snapshot mode (default: 100). If limit is provided, it takes precedence."
1228
+ description: "Max messages in snapshot mode (default: 100). limit takes precedence."
1423
1229
  },
1424
1230
  offset: {
1425
1231
  type: "number",
1426
- description: "Skip this many messages before returning (pagination; default 0)"
1232
+ description: "Skip this many messages before returning (default 0)"
1427
1233
  },
1428
1234
  countOnly: {
1429
1235
  type: "boolean",
@@ -1432,7 +1238,7 @@ Tip: If the returned elements do not include the specific element you need, use
1432
1238
  mode: {
1433
1239
  type: "string",
1434
1240
  enum: ["snapshot", "buffer"],
1435
- description: "Console capture mode: snapshot (default; waits ~2s for messages) or buffer (persistent per-tab buffer; reads from memory instantly)."
1241
+ description: "snapshot (default; waits ~2s) or buffer (persistent per-tab buffer; instant)."
1436
1242
  },
1437
1243
  buffer: {
1438
1244
  type: "boolean",
@@ -1440,23 +1246,23 @@ Tip: If the returned elements do not include the specific element you need, use
1440
1246
  },
1441
1247
  clear: {
1442
1248
  type: "boolean",
1443
- description: "Buffer mode only: clear the buffered logs for this tab before reading (default: false). Use clearAfterRead instead to clear after reading (mcp-tools.js style)."
1249
+ description: "Buffer mode: clear the buffered logs before reading (default: false)."
1444
1250
  },
1445
1251
  clearAfterRead: {
1446
1252
  type: "boolean",
1447
- description: "Buffer mode only: clear the buffered logs for this tab AFTER reading, to avoid duplicate messages on subsequent calls (default: false). This matches mcp-tools.js behavior."
1253
+ description: "Buffer mode: clear the buffered logs AFTER reading (avoids duplicates). Default: false"
1448
1254
  },
1449
1255
  pattern: {
1450
1256
  type: "string",
1451
- description: "Optional regex filter applied to message/exception text. Supports /pattern/flags syntax."
1257
+ description: "Regex filter on message/exception text. Supports /pattern/flags."
1452
1258
  },
1453
1259
  onlyErrors: {
1454
1260
  type: "boolean",
1455
- description: "Only return error-level console messages (and exceptions when includeExceptions=true). Default: false."
1261
+ description: "Only error-level messages (plus exceptions if includeExceptions). Default: false."
1456
1262
  },
1457
1263
  limit: {
1458
1264
  type: "number",
1459
- description: "Limit returned console messages. In snapshot mode this is an alias for maxMessages; in buffer mode it limits returned messages from the buffer."
1265
+ description: "Limit returned messages (snapshot: alias for maxMessages; buffer: from the buffer)."
1460
1266
  }
1461
1267
  },
1462
1268
  required: []
@@ -1464,7 +1270,7 @@ Tip: If the returned elements do not include the specific element you need, use
1464
1270
  },
1465
1271
  {
1466
1272
  name: TOOL_NAMES.BROWSER.FILE_UPLOAD,
1467
- description: "Upload files to web forms with file input elements using Chrome DevTools Protocol",
1273
+ description: "Upload files to file-input form elements using Chrome DevTools Protocol",
1468
1274
  inputSchema: {
1469
1275
  type: "object",
1470
1276
  properties: {
@@ -1475,7 +1281,7 @@ Tip: If the returned elements do not include the specific element you need, use
1475
1281
  },
1476
1282
  selector: {
1477
1283
  type: "string",
1478
- description: 'CSS selector for the file input element (input[type="file"])'
1284
+ description: 'CSS selector for the file input (input[type="file"])'
1479
1285
  },
1480
1286
  filePath: {
1481
1287
  type: "string",
@@ -1483,7 +1289,7 @@ Tip: If the returned elements do not include the specific element you need, use
1483
1289
  },
1484
1290
  fileUrl: {
1485
1291
  type: "string",
1486
- description: "URL to download file from before uploading"
1292
+ description: "URL to download the file from before uploading"
1487
1293
  },
1488
1294
  base64Data: {
1489
1295
  type: "string",
@@ -1491,7 +1297,7 @@ Tip: If the returned elements do not include the specific element you need, use
1491
1297
  },
1492
1298
  fileName: {
1493
1299
  type: "string",
1494
- description: 'Optional filename when using base64 or URL (default: "uploaded-file")'
1300
+ description: 'Filename for base64/URL (default "uploaded-file"). Name only; path separators or ".." rejected.'
1495
1301
  },
1496
1302
  multiple: {
1497
1303
  type: "boolean",
@@ -1512,17 +1318,14 @@ Tip: If the returned elements do not include the specific element you need, use
1512
1318
  type: "string",
1513
1319
  description: "Optional prompt text when accepting a prompt"
1514
1320
  },
1515
- tabId: {
1516
- type: "number",
1517
- description: "Optional target tab id. Defaults to the MCP work tab (background work mode) or the active tab."
1518
- }
1321
+ tabId: tabIdProp
1519
1322
  },
1520
1323
  required: ["action"]
1521
1324
  }
1522
1325
  },
1523
1326
  {
1524
1327
  name: TOOL_NAMES.BROWSER.REQUEST_USER_CONSENT,
1525
- description: 'Request user consent BEFORE invoking sensitive site features (camera, microphone, geolocation). Returns { approved, source } JSON. If the matching popup toggle is ON, returns { approved: true, source: "toggle" } immediately and sticky-sets the current active tab origin to allow via chrome.contentSettings (camera/mic/location). If OFF, opens a small consent popup window and awaits the user response (max 60s). auto-chrome-mcp fork v1.0.32+ (geolocation moved from bulk-install to per-origin consent gate for parity with camera/mic and OS-permission consistency); design: docs/plans/2026-05-29-site-permissions-design.md.',
1328
+ description: "Request user consent BEFORE using sensitive site features (camera, microphone, geolocation). Returns { approved, source }. If the matching popup toggle is ON, returns approved immediately and sticky-allows the current tab origin (chrome.contentSettings); if OFF, opens a consent popup and awaits the user (max 60s).",
1526
1329
  inputSchema: {
1527
1330
  type: "object",
1528
1331
  properties: {
@@ -1533,7 +1336,7 @@ Tip: If the returned elements do not include the specific element you need, use
1533
1336
  },
1534
1337
  reason: {
1535
1338
  type: "string",
1536
- description: 'Human-readable explanation shown to the user in the consent window (e.g. "\uB179\uD654 \uC2DC\uC791\uC744 \uC704\uD574 \uB9C8\uC774\uD06C\uC5D0 \uC811\uADFC\uD569\uB2C8\uB2E4").'
1339
+ description: 'Explanation shown to the user in the consent window (e.g. "\uB179\uD654 \uC2DC\uC791\uC744 \uC704\uD574 \uB9C8\uC774\uD06C\uC5D0 \uC811\uADFC\uD569\uB2C8\uB2E4").'
1537
1340
  }
1538
1341
  },
1539
1342
  required: ["action", "reason"]
@@ -1541,66 +1344,66 @@ Tip: If the returned elements do not include the specific element you need, use
1541
1344
  },
1542
1345
  {
1543
1346
  name: TOOL_NAMES.BROWSER.GIF_RECORDER,
1544
- description: 'Record browser tab activity as an animated GIF.\n\nModes:\n- Fixed FPS mode (action="start"): Captures frames at regular intervals. Good for animations/videos.\n- Auto-capture mode (action="auto_start"): Captures frames automatically when chrome_computer or chrome_navigate actions succeed. Better for interaction recordings with natural pacing.\n\nUse "stop" to end recording and save the GIF.',
1347
+ description: 'Record browser tab activity as an animated GIF. action="start" records at a fixed FPS (good for animations); action="auto_start" captures a frame whenever a chrome_computer or chrome_navigate action succeeds (better-paced interaction recordings). Use "stop" to end and save.',
1545
1348
  inputSchema: {
1546
1349
  type: "object",
1547
1350
  properties: {
1548
1351
  action: {
1549
1352
  type: "string",
1550
1353
  enum: ["start", "stop", "status", "auto_start", "capture", "clear", "export"],
1551
- description: 'Action to perform:\n- "start": Begin fixed-FPS recording (captures frames at regular intervals)\n- "auto_start": Begin auto-capture mode (frames captured on tool actions)\n- "stop": End recording and save GIF\n- "status": Get current recording state\n- "capture": Manually trigger a frame capture in auto mode\n- "clear": Clear all recording state and cached GIF without saving\n- "export": Export the last recorded GIF (download or drag&drop upload)'
1354
+ description: "start = fixed-FPS recording; auto_start = auto-capture (frames on tool actions); stop = end and save; status = current state; capture = manually grab a frame in auto mode; clear = drop state without saving; export = download or drag&drop-upload the last GIF."
1552
1355
  },
1553
1356
  tabId: {
1554
1357
  type: "number",
1555
- description: 'Target tab ID (default: active tab). Used with "start"/"auto_start" for recording, and with "export" (download=false) for drag&drop upload target.'
1358
+ description: "Target tab (default active tab). For start/auto_start, and export (download=false) drag&drop target."
1556
1359
  },
1557
1360
  fps: {
1558
1361
  type: "number",
1559
- description: "Frames per second for fixed-FPS mode (1-30, default: 5). Higher values = smoother but larger file."
1362
+ description: "FPS for fixed-FPS mode (1-30, default: 5)."
1560
1363
  },
1561
1364
  durationMs: {
1562
1365
  type: "number",
1563
- description: "Maximum recording duration in milliseconds (default: 5000, max: 60000). Only for fixed-FPS mode."
1366
+ description: "Max duration in ms (default: 5000, max: 60000). Fixed-FPS only."
1564
1367
  },
1565
1368
  maxFrames: {
1566
1369
  type: "number",
1567
- description: "Maximum number of frames to capture (default: 50 for fixed-FPS, 100 for auto mode, max: 300)."
1370
+ description: "Max frames (default: 50 fixed-FPS, 100 auto; max: 300)."
1568
1371
  },
1569
1372
  width: {
1570
1373
  type: "number",
1571
- description: "Output GIF width in pixels (default: 800, max: 1920)."
1374
+ description: "Output width in px (default: 800, max: 1920)."
1572
1375
  },
1573
1376
  height: {
1574
1377
  type: "number",
1575
- description: "Output GIF height in pixels (default: 600, max: 1080)."
1378
+ description: "Output height in px (default: 600, max: 1080)."
1576
1379
  },
1577
1380
  maxColors: {
1578
1381
  type: "number",
1579
- description: "Maximum colors in palette (default: 256). Lower values = smaller file size."
1382
+ description: "Max palette colors (default: 256). Lower = smaller file."
1580
1383
  },
1581
1384
  filename: {
1582
1385
  type: "string",
1583
- description: "Output filename (without extension). Defaults to timestamped name."
1386
+ description: "Output filename (no extension). Defaults to a timestamped name."
1584
1387
  },
1585
1388
  captureDelayMs: {
1586
1389
  type: "number",
1587
- description: "Auto-capture mode only: Delay in ms after action before capturing frame (default: 150). Allows UI to stabilize."
1390
+ description: "Auto mode: delay in ms after an action before capturing (default: 150)."
1588
1391
  },
1589
1392
  frameDelayCs: {
1590
1393
  type: "number",
1591
- description: "Auto-capture mode only: Display duration per frame in centiseconds (default: 20 = 200ms per frame)."
1394
+ description: "Auto mode: display duration per frame in centiseconds (default: 20 = 200ms)."
1592
1395
  },
1593
1396
  annotation: {
1594
1397
  type: "string",
1595
- description: 'Auto-capture mode only (action="capture"): Optional text label to render on the captured frame.'
1398
+ description: 'Auto mode (action="capture"): optional text label on the frame.'
1596
1399
  },
1597
1400
  download: {
1598
1401
  type: "boolean",
1599
- description: "Export action only: Set to true (default) to download the GIF, or false to upload via drag&drop."
1402
+ description: "Export only: true (default) to download, false to upload via drag&drop."
1600
1403
  },
1601
1404
  coordinates: {
1602
1405
  type: "object",
1603
- description: "Export action only (when download=false): Target coordinates for drag&drop upload.",
1406
+ description: "Export (download=false): target coordinates for drag&drop.",
1604
1407
  properties: {
1605
1408
  x: { type: "number" },
1606
1409
  y: { type: "number" }
@@ -1609,15 +1412,15 @@ Tip: If the returned elements do not include the specific element you need, use
1609
1412
  },
1610
1413
  ref: {
1611
1414
  type: "string",
1612
- description: "Export action only (when download=false): Element ref from chrome_read_page for drag&drop target."
1415
+ description: "Export (download=false): element ref for the drag&drop target."
1613
1416
  },
1614
1417
  selector: {
1615
1418
  type: "string",
1616
- description: "Export action only (when download=false): CSS selector for drag&drop target element."
1419
+ description: "Export (download=false): CSS selector for the drag&drop target."
1617
1420
  },
1618
1421
  enhancedRendering: {
1619
1422
  type: "object",
1620
- description: "Auto-capture mode only: Configure visual overlays for recorded actions (click indicators, drag paths, labels). Pass `true` to enable all defaults.",
1423
+ description: "Auto mode: visual overlays for recorded actions. Pass `true` for all defaults, or an object. Each overlay group accepts true or an object with the listed props (all optional, sensible defaults).",
1621
1424
  properties: {
1622
1425
  clickIndicators: {
1623
1426
  oneOf: [
@@ -1625,31 +1428,16 @@ Tip: If the returned elements do not include the specific element you need, use
1625
1428
  {
1626
1429
  type: "object",
1627
1430
  properties: {
1628
- enabled: {
1629
- type: "boolean",
1630
- description: "Enable click indicators (default: true)"
1631
- },
1632
- color: {
1633
- type: "string",
1634
- description: 'CSS color for click indicator (default: "rgba(255, 87, 34, 0.8)")'
1635
- },
1636
- radius: { type: "number", description: "Initial radius in px (default: 20)" },
1637
- animationDurationMs: {
1638
- type: "number",
1639
- description: "Animation duration in ms (default: 400)"
1640
- },
1641
- animationFrames: {
1642
- type: "number",
1643
- description: "Number of animation frames (default: 3)"
1644
- },
1645
- animationIntervalMs: {
1646
- type: "number",
1647
- description: "Interval between animation frames in ms (default: 80)"
1648
- }
1431
+ enabled: { type: "boolean" },
1432
+ color: { type: "string" },
1433
+ radius: { type: "number" },
1434
+ animationDurationMs: { type: "number" },
1435
+ animationFrames: { type: "number" },
1436
+ animationIntervalMs: { type: "number" }
1649
1437
  }
1650
1438
  }
1651
1439
  ],
1652
- description: "Click indicator overlay config (true for defaults, or object for custom)."
1440
+ description: "Click indicator overlay."
1653
1441
  },
1654
1442
  dragPaths: {
1655
1443
  oneOf: [
@@ -1657,28 +1445,15 @@ Tip: If the returned elements do not include the specific element you need, use
1657
1445
  {
1658
1446
  type: "object",
1659
1447
  properties: {
1660
- enabled: {
1661
- type: "boolean",
1662
- description: "Enable drag path rendering (default: true)"
1663
- },
1664
- color: {
1665
- type: "string",
1666
- description: 'CSS color for drag path (default: "rgba(33, 150, 243, 0.7)")'
1667
- },
1668
- lineWidth: { type: "number", description: "Line width in px (default: 3)" },
1669
- lineDash: {
1670
- type: "array",
1671
- items: { type: "number" },
1672
- description: "Dash pattern (default: [6, 4])"
1673
- },
1674
- arrowSize: {
1675
- type: "number",
1676
- description: "Arrow head size in px (default: 10)"
1677
- }
1448
+ enabled: { type: "boolean" },
1449
+ color: { type: "string" },
1450
+ lineWidth: { type: "number" },
1451
+ lineDash: { type: "array", items: { type: "number" } },
1452
+ arrowSize: { type: "number" }
1678
1453
  }
1679
1454
  }
1680
1455
  ],
1681
- description: "Drag path overlay config (true for defaults, or object for custom)."
1456
+ description: "Drag path overlay."
1682
1457
  },
1683
1458
  labels: {
1684
1459
  oneOf: [
@@ -1686,37 +1461,24 @@ Tip: If the returned elements do not include the specific element you need, use
1686
1461
  {
1687
1462
  type: "object",
1688
1463
  properties: {
1689
- enabled: {
1690
- type: "boolean",
1691
- description: "Enable action labels (default: true)"
1692
- },
1693
- font: {
1694
- type: "string",
1695
- description: 'Font for labels (default: "bold 12px sans-serif")'
1696
- },
1697
- textColor: { type: "string", description: 'Text color (default: "#fff")' },
1698
- bgColor: {
1699
- type: "string",
1700
- description: 'Background color (default: "rgba(0,0,0,0.7)")'
1701
- },
1702
- padding: { type: "number", description: "Padding in px (default: 4)" },
1703
- borderRadius: {
1704
- type: "number",
1705
- description: "Border radius in px (default: 4)"
1706
- },
1464
+ enabled: { type: "boolean" },
1465
+ font: { type: "string" },
1466
+ textColor: { type: "string" },
1467
+ bgColor: { type: "string" },
1468
+ padding: { type: "number" },
1469
+ borderRadius: { type: "number" },
1707
1470
  offset: {
1708
1471
  type: "object",
1709
- properties: { x: { type: "number" }, y: { type: "number" } },
1710
- description: "Offset from action position (default: {x: 10, y: -20})"
1472
+ properties: { x: { type: "number" }, y: { type: "number" } }
1711
1473
  }
1712
1474
  }
1713
1475
  }
1714
1476
  ],
1715
- description: "Action label overlay config (true for defaults, or object for custom)."
1477
+ description: "Action label overlay."
1716
1478
  },
1717
1479
  durationMs: {
1718
1480
  type: "number",
1719
- description: "How long overlays remain visible in ms (default: 1500)."
1481
+ description: "How long overlays stay visible in ms (default: 1500)."
1720
1482
  }
1721
1483
  }
1722
1484
  }
@@ -1727,14 +1489,14 @@ Tip: If the returned elements do not include the specific element you need, use
1727
1489
  // ===== auto-chrome-mcp fork (B1~B4) =====
1728
1490
  {
1729
1491
  name: TOOL_NAMES.BROWSER.STORAGE,
1730
- description: "Read or modify cookies, localStorage, or sessionStorage. Use it to save/restore a login session, test the logged-out state, pre-seed a consent cookie so the banner never appears, or inspect front-end state. Cookie/storage VALUES are hidden by default (names, domains and expiry are still returned) - pass includeValues:true only when you actually need the secrets.",
1492
+ description: "Read or modify cookies, localStorage, or sessionStorage. Use it to save/restore a login session, test the logged-out state, pre-seed a consent cookie, or inspect front-end state. VALUES are masked by default (names/domains/expiry still returned); pass includeValues:true only when you need the secrets.",
1731
1493
  inputSchema: {
1732
1494
  type: "object",
1733
1495
  properties: {
1734
1496
  kind: {
1735
1497
  type: "string",
1736
1498
  enum: ["cookies", "local", "session"],
1737
- description: 'What to operate on: browser cookies, localStorage, or sessionStorage. Default "cookies".'
1499
+ description: 'cookies, localStorage, or sessionStorage. Default "cookies".'
1738
1500
  },
1739
1501
  action: {
1740
1502
  type: "string",
@@ -1766,30 +1528,24 @@ Tip: If the returned elements do not include the specific element you need, use
1766
1528
  },
1767
1529
  includeValues: {
1768
1530
  type: "boolean",
1769
- description: "Return real values instead of masked placeholders. Default false - these are usually auth tokens."
1531
+ description: "Return real values instead of masks. Default false (usually auth tokens)."
1770
1532
  },
1771
1533
  tabId: { type: "number", description: "Target tab. Defaults to the session work tab." },
1772
- windowId: {
1773
- type: "number",
1774
- description: "Window to pick the active tab from (when tabId is omitted)."
1775
- }
1534
+ windowId: windowIdProp
1776
1535
  }
1777
1536
  }
1778
1537
  },
1779
1538
  {
1780
1539
  name: TOOL_NAMES.BROWSER.SAVE_PDF,
1781
- description: "Save the page as a PDF into the Downloads folder (via Page.printToPDF). Unlike a screenshot the text stays selectable and multi-page documents are captured in full - use it to archive notices, contracts, invoices and reports. The PDF bytes are NOT returned (that would be enormous); the result carries the saved filename.",
1540
+ description: "Save the page as a PDF into Downloads (via Page.printToPDF). Unlike a screenshot the text stays selectable and multi-page documents are captured in full; use it to archive notices, contracts, invoices, reports. The PDF bytes are NOT returned (too large); the result carries the saved filename.",
1782
1541
  inputSchema: {
1783
1542
  type: "object",
1784
1543
  properties: {
1785
1544
  tabId: { type: "number", description: "Target tab. Defaults to the session work tab." },
1786
- windowId: {
1787
- type: "number",
1788
- description: "Window to pick the active tab from (when tabId is omitted)."
1789
- },
1545
+ windowId: windowIdProp,
1790
1546
  filename: {
1791
1547
  type: "string",
1792
- description: 'File name (".pdf" added automatically). Saved under Downloads/mcp-pdf/.'
1548
+ description: 'File name (".pdf" added). Saved under Downloads/mcp-pdf/.'
1793
1549
  },
1794
1550
  paperFormat: {
1795
1551
  type: "string",
@@ -1819,7 +1575,7 @@ Tip: If the returned elements do not include the specific element you need, use
1819
1575
  },
1820
1576
  {
1821
1577
  name: TOOL_NAMES.BROWSER.EMULATE,
1822
- description: 'Emulate a device viewport (size, pixel density, touch, User-Agent) on a tab for responsive/mobile checking. The real window is never resized, so this works on background work tabs. Emulation persists until action="reset" - always reset when finished, since Chrome shows an automation notice on an emulated tab.',
1578
+ description: 'Emulate a device viewport (size, pixel density, touch, User-Agent) on a tab for responsive/mobile checking. The real window is never resized, so it works on background work tabs. Emulation persists until action="reset"; always reset when done (Chrome shows an automation notice on an emulated tab).',
1823
1579
  inputSchema: {
1824
1580
  type: "object",
1825
1581
  properties: {
@@ -1848,28 +1604,25 @@ Tip: If the returned elements do not include the specific element you need, use
1848
1604
  hasTouch: { type: "boolean", description: "Enable touch event emulation." },
1849
1605
  userAgent: { type: "string", description: "Override the User-Agent string." },
1850
1606
  tabId: { type: "number", description: "Target tab. Defaults to the session work tab." },
1851
- windowId: {
1852
- type: "number",
1853
- description: "Window to pick the active tab from (when tabId is omitted)."
1854
- }
1607
+ windowId: windowIdProp
1855
1608
  }
1856
1609
  }
1857
1610
  },
1858
1611
  {
1859
1612
  name: TOOL_NAMES.BROWSER.NETWORK_RULES,
1860
- description: "Block network requests with declarativeNetRequest session rules. Blocking ads/trackers or heavy images makes pages load noticeably faster and cuts the boilerplate that read_page/get_web_content would otherwise return (fewer tokens). Rules are session-scoped (gone on Chrome restart) and can be limited to one tab. Beware: some sites depend on tracker domains for login.",
1613
+ description: "Block network requests with declarativeNetRequest session rules. Blocking ads/trackers or heavy images speeds up pages and cuts boilerplate tokens. Rules are session-scoped (gone on Chrome restart) and can be limited to one tab. Note: some sites need tracker domains for login.",
1861
1614
  inputSchema: {
1862
1615
  type: "object",
1863
1616
  properties: {
1864
1617
  action: {
1865
1618
  type: "string",
1866
1619
  enum: ["block", "unblock", "list", "clear"],
1867
- description: 'Default "block". "list" shows active rules with their ids, "clear" removes all of them.'
1620
+ description: 'Default "block". "list" shows active rules with ids, "clear" removes all.'
1868
1621
  },
1869
1622
  preset: {
1870
1623
  type: "string",
1871
1624
  enum: ["ads", "trackers", "images", "media", "fonts"],
1872
- description: "Built-in rule set. ads/trackers block known domains; images/media/fonts block those resource types entirely."
1625
+ description: "Rule set: ads/trackers block known domains; images/media/fonts block those resource types."
1873
1626
  },
1874
1627
  patterns: {
1875
1628
  type: "array",
@@ -1883,7 +1636,7 @@ Tip: If the returned elements do not include the specific element you need, use
1883
1636
  ruleIds: {
1884
1637
  type: "array",
1885
1638
  items: { type: "number" },
1886
- description: 'For action="unblock": rule ids to remove (get them from action="list").'
1639
+ description: 'action="unblock": rule ids to remove (from action="list").'
1887
1640
  }
1888
1641
  }
1889
1642
  }
@@ -1896,10 +1649,16 @@ var LANE_EXEMPT_TOOLS = /* @__PURE__ */ new Set([
1896
1649
  TOOL_NAMES.BROWSER.BOOKMARK_SEARCH,
1897
1650
  TOOL_NAMES.BROWSER.BOOKMARK_ADD,
1898
1651
  TOOL_NAMES.BROWSER.BOOKMARK_DELETE,
1899
- TOOL_NAMES.BROWSER.REQUEST_USER_CONSENT
1652
+ TOOL_NAMES.BROWSER.REQUEST_USER_CONSENT,
1653
+ // record_replay 두 도구는 레인 대상이 아니다: flow_run 은 대상 탭을 엔진이 스스로 잡아
1654
+ // 레인→작업탭 주입 경로를 타지 않고, list_published 는 순수 조회다. 지금은 두 스키마가
1655
+ // 위에서 주석 처리돼 TOOL_SCHEMAS 에 없으므로 이 항목은 실질적으로 무효지만, 다시 노출할 때
1656
+ // 판단을 되풀이하지 않도록 남겨 둔다.
1657
+ TOOL_NAMES.RECORD_REPLAY.FLOW_RUN,
1658
+ TOOL_NAMES.RECORD_REPLAY.LIST_PUBLISHED
1900
1659
  ]);
1901
- var LANE_DESCRIPTION_SHORT = 'Parallel lane id. Concurrent agents share one MCP session \u2014 give each agent its own lane (e.g. "agent-1") and pass it on every call so they get isolated work tabs. Omit when not parallel.';
1902
- var LANE_DESCRIPTION_LONG = 'Parallel lane id. Sub-agents of one Claude Code session share a single MCP session, so without a lane they overwrite each other\u2019s work tab. Give each concurrent agent a distinct lane (e.g. "agent-1") and pass the SAME lane on every subsequent call: the tab opened for a lane is never retargeted or closed by another lane. Omit when not running agents in parallel.';
1660
+ var LANE_DESCRIPTION_SHORT = "Parallel-agent lane id (same value every call). Omit if solo.";
1661
+ var LANE_DESCRIPTION_LONG = "Parallel lane id. Sub-agents of one Claude Code session share one MCP session, so without a lane they overwrite each other's work tab. Give each concurrent agent a distinct lane (same value every call): a lane keeps its own work tab that no other lane closes or retargets.";
1903
1662
  for (const tool of TOOL_SCHEMAS) {
1904
1663
  if (LANE_EXEMPT_TOOLS.has(tool.name)) continue;
1905
1664
  const schema = tool.inputSchema;