Skip to main content
Glama

retry_click

Retries clicking an element when timing, overlays, or stale re-renders cause intermittent failures; waits for visibility and enabled state before each attempt.

Instructions

Click with retries, for clicks that fail intermittently: the element is covered by a loading overlay or animation, or re-rendered (stale) between being found and clicked. Each attempt waits for the element to be visible and enabled, then clicks; failed attempts pause delayMs before the next. Returns the attempt that succeeded, or every attempt's error. Try click first; use this when click failed because of timing.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
delayMsNoPause between failed attempts, in milliseconds (default 250).
attemptsNoMaximum click attempts, 1-10 (default 3).
selectorYesHow to find the element, e.g. { by: 'css', value: '#login-button' } or { by: 'id', value: 'user-name' }. Prefer id, name, or a short CSS selector.
timeoutMsNoHow long each attempt waits for the element to become visible and enabled, in milliseconds (default 10000).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv0.3.0
    • addedInput schema / properties / attempts / description
      Added value: +"Maximum click attempts, 1-10 (default 3)."
    • addedInput schema / properties / delayMs / description
      Added value: +"Pause between failed attempts, in milliseconds (default 250)."
    • addedInput schema / properties / selector / description
      Added value: +"How to find the element, e.g. { by: 'css', value: '#login-button' } or { by: 'id', value: 'user-name' }. Prefer id, name, or a short CSS selector."
    • addedInput schema / properties / selector / properties / by / description
      Added value: +"Locator strategy: css, xpath, id, name, class/className, tag/tagName, linkText, or partialLinkText."
    • addedInput schema / properties / selector / properties / value / description
      Added value: +"The locator for that strategy, e.g. '#login-button' for css, 'user-name' for id, or //button[@type=\"submit\"] for xpath."
    • addedInput schema / properties / timeoutMs / description
      Added value: +"How long each attempt waits for the element to become visible and enabled, in milliseconds (default 10000)."
  2. First observedv0.1.2

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses the retry loop, that each attempt waits for the element to be visible and enabled, the inter-attempt pause, and the return behavior on success vs. total failure. It omits any note on side effects of the click itself or whether the retry re-resolves the selector, but the core dynamics are covered.

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?

Front-loaded with purpose and failure modes, then mechanism, then return values. Dense and mostly waste-free; the middle clause enumerating failure modes is slightly verbose but earns its place by clarifying when to choose this tool.

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

Completeness4/5

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

No output schema exists, yet the description covers the return contract ("the attempt that succeeded, or every attempt's error"), which is what an agent needs. Combined with fully-covered parameters and explicit usage routing, it is essentially complete for a retry-click tool.

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%, so all four parameters are already documented, including delayMs and attempts. The description only loosely echoes these ("failed attempts pause delayMs"), adding little beyond what the schema states, so the baseline 3 is appropriate.

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?

Opens with a specific verb+resource ("Click with retries") and immediately scopes it to "clicks that fail intermittently," naming the concrete failure modes (loading overlay, animation, stale re-render). This distinguishes it cleanly from the sibling `click` tool.

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

Usage Guidelines5/5

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

Explicitly routes the agent: "Try click first; use this when click failed because of timing." This states both the preferred alternative and the exact condition that selects this tool, leaving nothing to inference.

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