Skip to main content
Glama

trace_path

Trace screen-reader navigation paths to interactive targets, mapping step-by-step actions and cumulative accessibility cost to diagnose navigation barriers.

Instructions

Trace the exact screen-reader navigation path to a specific interactive target. Returns step-by-step actions a screen-reader user would perform, with modeled announcements, cumulative cost, and the target's role/name at each hop. Read-only — navigates to the URL but does not modify the page.

Use this after analyze_url to understand why a target scored poorly.

For auth-gated or explored targets: Pass statesJson from a prior analyze_url (use includeStates=true). This skips browser launch entirely and traces against the captured state, including any explored states discovered behind auth boundaries. Workflow: analyze_url(includeStates=true, explore=true) → extract result.states → trace_path(statesJson=JSON.stringify(states), target='search').

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesURL of the page to trace
targetYesTarget to trace to. Can be an exact target ID from an analysis result, or a glob pattern to match target names (e.g., '*search*', 'Submit*'). Case-insensitive.
profileNoAT profile IDgeneric-mobile-web-sr-v0
deviceNoPlaywright device name for emulation (e.g., 'iPhone 14')
waitForSelectorNoCSS selector to wait for before capturing (essential for SPAs)
exploreNoExplore hidden branches (menus, tabs, dialogs) before tracing
timeoutNoPage load timeout in milliseconds
statesJsonNoPre-captured states from a prior analyze_url run. Pass the 'states' array from the JSON output (use includeStates=true on analyze_url to include it). When provided, trace_path skips browser launch and traces against the captured state. Workflow: analyze_url(includeStates=true) → extract result.states → trace_path(statesJson=...).
storageStateNoPath to Playwright storageState JSON for authenticated pages. Use save_auth to create.
Behavior4/5

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

No annotations provided, but description explicitly states 'Read-only — navigates to the URL but does not modify the page' and notes that statesJson 'skips browser launch entirely'. Could improve by mentioning timeout/failure behavior, but covers primary side effects well.

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?

Perfectly structured with front-loaded purpose ('Trace the exact...'), immediate return value disclosure, read-only warning, and bolded section for complex auth workflow. Every sentence serves distinct purpose; zero redundancy despite 9 parameters.

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?

For a complex 9-parameter tool with no output schema, description comprehensively covers return structure ('step-by-step actions... modeled announcements, cumulative cost'), auth scenarios, SPA handling (waitForSelector), and sibling tool relationships. Complete without being verbose.

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%, establishing baseline 3. Description adds valuable workflow semantics explaining how target relates to analyze_url results (exact ID vs glob) and the specific statesJson workflow chain (analyze_url → extract → trace_path), which adds meaning beyond isolated parameter definitions.

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?

Description uses specific verb 'Trace' with resource 'screen-reader navigation path' and clearly distinguishes from sibling analyze_url by stating it explains 'why a target scored poorly' and should be used 'after analyze_url'.

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 states when to use ('after analyze_url to understand why a target scored poorly') and provides detailed workflow for auth-gated targets using statesJson from analyze_url with includeStates=true. Clearly positions tool in the analysis workflow chain.

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/tactual-dev/tactual'

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