Skip to main content
Glama

click

Activates a webpage element by CSS selector, with optional waits for page navigation, async UI, or a specific element after activation.

Instructions

Click an element by CSS selector.

Args: selector: CSS selector for the element to click. wait_for_navigation: Wait for a page load after clicking (default True). Set to False for clicks that trigger in-page UI changes like modals, dropdowns, or expanding sections. wait_for: CSS selector to wait for AFTER clicking — use this when the click opens a modal or triggers async UI rendering. The tool waits up to 5 s for the element to appear before returning. wait_ms: Extra milliseconds to wait after the click before reading the page. Useful for SPAs where JS hydration takes a moment (e.g. 500–2000).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
wait_msNo
selectorYes
wait_forNo
wait_for_navigationNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries full responsibility for disclosing behavioral traits. It reveals important timing behaviors: wait_for_navigation defaults to True, wait_for waits up to 5 seconds for an element to appear, and wait_ms adds extra delay for SPA hydration. It does not mention error handling (e.g., element not found), but the disclosed timing semantics are valuable and not obvious from the schema alone.

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: a one-sentence summary followed by a tagged list of arguments. Each parameter explanation is concise and directly useful, with no fluff. The format is scannable and front-loads the core purpose before diving into details.

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?

Given the tool's moderate complexity (4 params, one required), the description covers all key aspects: what the tool does, when to use different waiting strategies, and how to handle async UI changes. It provides enough context for an agent to invoke the tool correctly in common scenarios. The presence of an output schema means return values do not need to be described here.

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?

The input schema has 0% description coverage — parameters only have titles and defaults. The tool description compensates fully by explaining each parameter in detail: selector (the CSS selector), wait_for_navigation (with guidance on when to set False), wait_for (with its 5-second timeout), and wait_ms (with use cases like SPA hydration). This adds significant meaning beyond the bare 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 opens with a clear, specific statement: 'Click an element by CSS selector.' This identifies both the action (click) and the resource (element by CSS selector), distinguishing it from sibling tools like fill_field, submit_form, and navigate. There is no ambiguity about what the tool does.

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?

The description provides practical guidance on parameter usage, such as setting wait_for_navigation to False for 'clicks that trigger in-page UI changes like modals, dropdowns, or expanding sections' and using wait_for when 'the click opens a modal or triggers async UI rendering.' It does not explicitly name alternative tools, but the context for when to use this tool is clear and actionable.

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/Dominic-Pi-Sunyer/web-speed-agent'

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