Skip to main content
Glama
MCP Appium

MCP Appium

appium_verify_locator

Read-only

Counts live-screen matches for each locator so you can confirm exactly one safe match, flag ambiguous multiple matches, and detect absent elements before using locators in test code.

Instructions

Count matches for each locator on the live screen. Only a count of exactly 1 is safe to put in test code; >1 is ambiguous, 0 is absent.

Input Schema

NameRequiredDescriptionDefault
locatorsYesLocators to check, same grammar as wait_for.
sessionIdNoSession ID; defaults to the active session.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.99.3

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, so safety is covered. The description adds real context beyond that: it operates against the live/current screen state rather than a cached snapshot, and it defines the interpretation thresholds for the returned counts. It says nothing about cost, timing, or whether the screen is re-queried per locator.

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, zero filler, with the action front-loaded and the interpretation rule immediately after. Nothing redundant or out of order.

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?

For a two-parameter read-only tool with no output schema, the description conveys the essential shape of the result (a count per locator) and how to read it. The only gap is that it does not state the literal return structure or whether mismatched locators are reported together, but that is a minor omission here.

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%, including the note that locators use the same grammar as wait_for and that sessionId defaults to the active session, so the schema already carries the parameter meaning. The description adds only that counts are produced per locator, without elaborating on the array or the session override. Baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: "Count matches for each locator on the live screen." That clearly separates it from the element-returning siblings (appium_find_element, appium_find_elements) and from appium_wait_for. It stops short of naming any sibling explicitly, so it lands at a clear-but-undifferentiated 4.

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?

It gives the decision rule for acting on the result: only a count of exactly 1 is safe for test code, >1 is ambiguous, 0 is absent. That tells the agent the situation this tool is for (validating a locator before committing it to a test). It does not mention when to skip this tool in favor of appium_wait_for or appium_locator_intel, so no explicit alternative routing.

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