Skip to main content
Glama

Navigate

navigate

Control React Navigation and Expo Router from outside the app: inspect the current stack, go to routes by name, push cards, go back, or reset navigation state.

Instructions

Read or drive react-navigation (and Expo Router) from outside the app. stack reports the current navigation state — one line per nesting level with the focused route marked. navigate/push go to a route by name (push always adds a new card, navigate reuses an existing one), back/pop/pop_to_top unwind it, reset replaces the whole state via resetRoot. Every mutating action reports the resulting stack. The navigation container ref is found by walking the React tree, so no app-side setup is needed; it is cached on globalThis.RNE_NAV until the next reload. An unknown route name comes back as react-navigation's own "was not handled by any navigator" message.

Input Schema

NameRequiredDescriptionDefault
nameNo
countNo
stateNo
actionYes
paramsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

No annotations are provided, so the description carries the full burden and does well: it discloses that no app-side setup is needed, that the container ref is cached on globalThis.__RNE_NAV__ until reload, that mutating actions report the resulting stack, and that unknown routes surface react-navigation's own error. It omits any note on reversibility or permissions for reset, which keeps it from a 5.

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?

Dense but front-loaded: the core purpose comes first, then per-action semantics, then the implementation caveat. Nearly every sentence earns its place; only the react-navigation error-message detail is borderline padding.

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

Completeness3/5

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

For a stateful, multi-action navigation tool with no output schema and 0% parameter coverage, the description explains behavior well but leaves four of five parameters unexplained, so an agent could still misuse count, state, or params on first call.

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 description coverage is 0%, so the description should compensate. It thoroughly explains the action enum, but name, params, state, and count (max 50) are never described — the agent must infer that count bounds pop/back, that state feeds reset, and that params are route params.

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?

States a specific verb and resource: 'Read or drive react-navigation (and Expo Router) from outside the app.' It then enumerates every action's effect, so the agent knows exactly what the tool is for and how each action differs from the others.

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?

Explicitly distinguishes push vs navigate ('push always adds a new card, navigate reuses an existing one') and groups the unwind actions, giving clear when-to-use guidance per action. It doesn't say when to pick this over UI siblings like tap or observe, so it stops short of a 5.

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