Skip to main content
Glama

browser

Destructive

Control web browsers via Chrome DevTools Protocol using DOM selectors for reliable automation. Navigate, click, type, read text, and manage tabs.

Instructions

Chrome DevTools Protocol control — operates on DOM elements by CSS selector rather than screen pixels. Start with navigate (opens the URL in the agent's own CDP browser, launching it if needed) or connect (attach to a browser already on the debug port), then page_context/click/type on that page. Much more reliable than computer for web automation. Pick an action: navigate, connect, page_context, read_text, click, type, select_option, evaluate, wait_for, list_tabs, switch_tab, scroll.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "action": "<action>"
    },
    "name": "browser"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoURL to navigate to
textNoVisible text of the element to click (preferred).
labelNoLabel text associated with the input (alternative to selector).
valueNoOption value or visible text to select
actionYesWhich sub-action to perform. See this tool's description for the enum of valid values. Required: navigate: url; type: text; select_option: selector, value; evaluate: javascript; wait_for: selector; switch_tab: target; scroll: direction.
amountNoPixels to scroll (default: 500)
expectNoOptional post-conditions to verify after this action (same assertion types as the verify tool: window_title_contains, app_running, element_exists, element_value_contains, clipboard_contains, file_exists, file_contains, ocr_contains, file_changed_since_start). If any FAIL the action returns a DEVIATION and you must adapt. State an OUTCOME you can observe (a window title, a rendered element/chip, a status) — NOT the raw text you typed.
targetNoURL or title substring to match
timeoutNoTimeout in milliseconds (default: 10000)
selectorNoOptional CSS selector to read text from (default: structured interactive-element list for the whole page).
directionNoScroll direction
maxLengthNoMax characters to return (default: 3000)
javascriptNoJavaScript code to evaluate in the page

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.5.24
    • changedInput schema / properties / action / description
      Previous value: -"Which sub-action to perform. See this tool's description for the enum of valid values."New value: +"Which sub-action to perform. See this tool's description for the enum of valid values. Required: navigate: url; type: text; select_option: selector, value; evaluate: javascript; wait_for: selector; switch_tab: target; scroll: direction."
    • addedInput schema / properties / expect
      Added value: +{
      +  "description": "Optional post-conditions to verify after this action (same assertion types as the verify tool: window_title_contains, app_running, element_exists, element_value_contains, clipboard_contains, file_exists, file_contains, ocr_contains, file_changed_since_start). If any FAIL the action returns a DEVIATION and you must adapt. State an OUTCOME you can observe (a window title, a rendered element/chip, a status) — NOT the raw text you typed.",
      +  "items": {
      +    "properties": {
      +      "type": {
      +        "enum": [
      +          "window_title_contains",
      +          "app_running",
      +          "element_exists",
      +          "element_value_contains",
      +          "clipboard_contains",
      +          "file_exists",
      +          "file_contains",
      +          "ocr_contains",
      +          "file_changed_since_start"
      +        ],
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "type"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  2. First observedv1.5.16

TDQS

A3.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true, openWorldHint=true and idempotentHint=false, so the safety profile is covered. The description adds genuine operational context — that the browser may be launched on demand or attached to an existing debug port. It does not mention that `evaluate` runs arbitrary JavaScript in the page or that actions mutate page state, which is the main residual risk left to annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the tool's operating model, then the entry-point rule, then the action list. Efficient overall, though the trailing action enumeration duplicates the enum already in the schema and could be trimmed.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers selection and the critical bootstrap sequence for a 13-parameter open-world tool. There is no output schema, and the description says nothing about what actions return (e.g. `page_context` yielding a structured interactive-element list, `evaluate` returning a value) or about the DEVIATION semantics of `expect`, which are left to the schema prose.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, including a per-action required-parameter map in the `action` enum description. The description's action list is a restatement of that enum and adds no per-action parameter semantics beyond it, so baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific mechanism (Chrome DevTools Protocol control) and a distinguishing operating model (DOM elements by CSS selector rather than screen pixels), which immediately separates it from the pixel-based `computer` tool. An agent can tell what this tool does without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives an explicit entry sequence — start with `navigate` (launches) or `connect` (attaches to an existing debug port), then operate on that page — and recommends this over `computer` for web automation. It lacks the inverse guidance (when to fall back to `computer`, e.g. non-browser or canvas-only UI).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools