Skip to main content
Glama
nayakprashant

Selenium MCP Server

get_accessibility_tree

Returns interactive elements with semantic roles and indices, enabling AI agents to understand UI structure and perform actions like clicking.

Instructions

Retrieve a simplified accessibility tree of the current page.

Purpose

Returns interactive elements with semantic roles so AI agents can understand UI meaning (buttons, links, inputs, dropdowns). Returned index values map directly to click_element.

Parameters

session_id : str Active browser session identifier.

Returns

dict { "session_id": str, "count": int, "nodes": [{"index": int, "role": str, "name": str, "tag": str, "id": str, "name_attr": str, "placeholder": str, "aria_label": str}], "status": str, "message": str }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
session_idYes
Behavior4/5

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

No annotations provided, so description carries full burden. It discloses the return structure and mapping to click_element, indicating a read-only operation. However, it does not explicitly state non-destructiveness or discuss performance implications.

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

Conciseness5/5

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

The description is well-structured with sections for purpose, parameters, and returns. It is concise yet informative, with no wasted sentences. Every part adds value.

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

Completeness5/5

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

The description completely covers the tool's inputs, outputs, and purpose. Despite lacking an output schema, it provides the full return format. The mapping to click_element adds contextual value for workflow integration.

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

Parameters5/5

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

With 0% schema description coverage, the description fully compensates by documenting the sole parameter session_id as 'Active browser session identifier', adding meaning beyond the schema type and title.

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?

The description clearly states it retrieves a simplified accessibility tree, returning interactive elements with semantic roles. It distinguishes itself by specifying 'simplified' and noting that index values map to click_element, providing specific verb and resource.

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

Usage Guidelines3/5

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

The description implies usage for understanding UI meaning and interacting via click_element, but does not explicitly state when to use versus alternatives like get_interactive_elements. No when-not or exclusion criteria are given.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nayakprashant/selenium-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server