Skip to main content
Glama
Wladastic

AutoProbeMCP

by Wladastic

click_element

Click a web page element using a CSS selector. Specify the selector and optional timeout to ensure the element is interacted with correctly.

Instructions

Click on an element by CSS selector

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
selectorYesCSS selector for the element to click
timeoutNoTimeout in milliseconds

Implementation Reference

  • Zod schema for click_element input validation: requires 'selector' (string) and optional 'timeout' (number, default 5000).
    const ClickElementSchema = z.object({
      selector: z.string(),
      timeout: z.number().default(5000)
    });
  • src/index.ts:178-195 (registration)
    Registration of the 'click_element' tool in the ListToolsRequestSchema handler, including description and input schema definition.
      name: 'click_element',
      description: 'Click on an element by CSS selector',
      inputSchema: {
        type: 'object',
        properties: {
          selector: {
            type: 'string',
            description: 'CSS selector for the element to click'
          },
          timeout: {
            type: 'number',
            default: 5000,
            description: 'Timeout in milliseconds'
          }
        },
        required: ['selector']
      }
    },
  • Handler for 'click_element' tool: validates input with ClickElementSchema, checks browser availability, uses Playwright's page.click() with the provided selector and timeout, and returns a success message.
    case 'click_element': {
      if (!currentPage) {
        throw new Error('No browser page available. Launch a browser first.');
      }
    
      const params = ClickElementSchema.parse(args);
      await currentPage.click(params.selector, { timeout: params.timeout });
    
      return {
        content: [
          {
            type: 'text',
            text: `Clicked element: ${params.selector}`
          }
        ]
      };
    }
Behavior2/5

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

Description does not disclose behavior beyond the action: e.g., whether it waits for the element, throws on missing element, or scrolls. With no annotations, this is insufficient.

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 description is very concise (one sentence) but omits important context. It is not so concise that it is complete.

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

Completeness2/5

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

Given complexity (action tool with no output schema) and siblings, the description fails to provide adequate context about behavior, error handling, or when to use.

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 100% with descriptions for both parameters. The tool description adds no additional meaning beyond what the schema already provides.

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 the verb 'Click' and resource 'element by CSS selector', which distinguishes it from sibling tools like get_element_text or type_text that use similar selectors for different actions.

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?

No guidance on when to use this tool versus alternatives (e.g., not for double-click or right-click). No mention of when not to use it.

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/Wladastic/AutoProbeMCP'

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