Skip to main content
Glama

get-element-info

Inspect page elements by snapshot reference, label, or role and name to read their text, visibility, enabled state, and bounds.

Instructions

Read text, visibility, enabled state and bounds of elements matched by snapshot reference, label, or role and name.

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": {
      "pageId": "<pageId>",
      "selector": "<selector>"
    },
    "name": "get-element-info"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageIdYes
selectorYes
sessionIdNoBrowser session ID. Defaults to 'default'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations, the description carries the full burden; it does signal a read operation by leading with 'Read' and enumerates the returned attributes. However, it says nothing about failure modes (element not found, stale snapshot ref, cross-session access), permission requirements, or whether the call mutates or focuses the page. Adequate but with material gaps for an unannotated tool.

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?

A single front-loaded sentence with the verb first and the returned attributes before the selector modes. No filler. It is tight, though the dense list-of-nouns phrasing takes a second read.

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?

There is no output schema, and the description does its part by naming the four returned properties, which is the right compensation. It still leaves required pageId unexplained and gives no selector-selection guidance among the three branches, which matters for a two-required-parameter tool with three distinct modes.

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 coverage is only 33%, so the description's enumeration of the three selector modes (snapshot ref, label, role+name) is genuinely useful and maps to the selector oneOf branches. It adds nothing for pageId, which is required but undocumented anywhere, and does not explain exact-match behavior or sessionId defaults beyond what the schema already says.

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?

States a specific verb (read) and resource (elements) plus the exact attributes returned: text, visibility, enabled state, and bounds. It also names the three selector modes, so an agent knows what input shapes are accepted. It stops short of distinguishing itself from get-element-snapshot or get-page-snapshot, so a sibling comparison still requires inference.

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 when-to-use or when-not-to-use guidance, and no named alternative. An agent must guess whether this or get-element-snapshot is the right call for inspecting a single element. The only implied usage is 'you need element attributes', which is thin.

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