Skip to main content
Glama
BrowserGenie

BrowserGenie MCP Server

by BrowserGenie

get_element_state

Check element state properties such as visibility, enablement, focus, and validity to verify conditions during testing.

Instructions

Get the state of an element: exists, visible, enabled, focused, checked, selected, readOnly, required, valid, and more. Essential for verifying element conditions during testing.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
selectorYesCSS selector or XPath expression
selectorTypeNoSelector typecss
tabIdNoTarget tab ID (defaults to currently active tab)
apiKeyNoAPI key for authentication if enabled
Behavior3/5

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

Without annotations, the description carries the burden of disclosing behavioral traits. It states it gets state but does not clarify if it returns a single object, waits for elements, or throws on failure. Side effects are implied non-existent but not confirmed.

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?

Two sentences with no wasted words. The purpose is front-loaded, and examples of state attributes are listed efficiently. Every sentence adds value.

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?

While input schema is complete, the description lacks details about return format (e.g., whether it returns a boolean per attribute or a structure) and error handling (e.g., behavior when element not found). Could be more informative for a tool with no output schema.

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

Parameters4/5

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

Schema coverage is 100% (all parameters described), but the description adds value by enumerating the state attributes, giving insight into the output. This helps agents understand what the tool returns, partially compensating for the missing output schema.

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 'Get the state of an element' and lists specific attributes (exists, visible, enabled, etc.), making the tool's purpose precise and distinct from sibling tools like assert_element or get_computed_styles.

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 says 'Essential for verifying element conditions during testing,' which implies a use case but does not explicitly distinguish when to use this tool versus alternatives like assert_element (which asserts conditions) or other get_* tools.

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/BrowserGenie/mcp'

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