Skip to main content
Glama
Browser MCP Server

Browser MCP Server

get_bounding_box

Retrieve an element's position and dimensions using a selector to help AI agents locate and interact with page elements accurately.

Instructions

Get element position and size.

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": {
      "selector": "<selector>"
    },
    "name": "get_bounding_box"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageIdNo
selectorYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

C2.7/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full disclosure burden and delivers almost nothing: it does not say whether the operation is read-only (implied but unstated), what coordinate frame the position is relative to (viewport vs. page vs. iframe), whether it scrolls the element into view, or how a not-found element is handled. For an inspection tool that returns geometric data, these omissions materially affect interpretation of the result.

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

Conciseness3/5

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

The single short sentence is front-loaded and waste-free, but the brevity comes from under-specification rather than economy — there is no structure carrying prerequisites, selector format, or return shape. Appropriate length, insufficient content.

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?

This is a low-complexity, two-parameter read tool with no nested objects, so a short description is defensible. However, with no annotations and no output schema, the description is the only place that could explain what "position and size" returns (field names, units, coordinate origin), and it does not.

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

Parameters2/5

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

Schema description coverage is 0% across both parameters, so the description must compensate and does not. "Element" hints that selector identifies the target, but the selector format (CSS, XPath, text) is unspecified, and pageId is not mentioned at all, leaving an entire parameter's meaning undefined.

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

Purpose4/5

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

The description pairs a specific verb ("Get") with a concrete resource ("element position and size"), which clearly reads as a bounding-box retrieval and is naturally distinguishable from siblings like get_element_text or get_element_attribute. It stops short of naming or contrasting any alternative, and never states how the element is identified, so it lands at a clear-but-undifferentiated 4.

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

Usage Guidelines2/5

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

There is no guidance on when to call this versus other element inspection tools, no prerequisitives such as a loaded page or valid selector, and no note on what to do when the element is missing. The agent must infer all usage context from the name alone.

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