Skip to main content
Glama
MCP Appium

MCP Appium

appium_session_health

Diagnose mobile test session health by checking device, server, app, and session state; identify failure type and optionally replace a dead session once without resetting app data.

Instructions

Diagnose a session: device state (adb), Appium server (remote), session liveness, app state and foreground, ANR dialog. Returns the failure kind with signals and whether replacing the session would help. With recover=true and only for a recoverable failure (dead session or driver), replaces the session once, bounded to 2 attempts per 10 minutes, never touches other sessions, never resets app data, relaunches the app and verifies the new session. Cloud and attached sessions are not replaced.

Input Schema

NameRequiredDescriptionDefault
appIdNoApp to check and restore (defaults to the session capability appPackage/bundleId).
detailNoReturn the full report even when healthy.
recoverNoIf the session is dead, delete it and create a new one with the same platform and capabilities. Default false (report only).
sessionIdNoSession ID; defaults to the active session.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.99.3

TDQS

A3.8/5.0
Behavior3/5

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

Annotations declare readOnlyHint=false and openWorldHint=false, so the mutating nature is already signalled; the description nonetheless adds real value with a rate bound (2 attempts per 10 minutes), scope guarantees (never touches other sessions, never resets app data), and the post-replacement verify step. It does not describe the shape of the returned signals or what the response looks like when recovery is attempted and fails.

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?

Two sentences, front-loaded with the diagnostic scope before the recovery caveats, and essentially no filler. The second sentence is dense and runs long with stacked caveats, which slightly hurts scanability.

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 zero-required-parameter diagnostic with no output schema, it covers what is checked, what is returned (failure kind plus signals plus a replacement verdict), and the exact guardrails on the one mutating path. Remaining gap is the response shape on a report-only call, which the description only summarizes.

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%, so baseline is 3; the description still adds meaning for recover by narrowing it to specific failure kinds and by disclosing the retry ceiling, which the schema property text does not contain. It says nothing extra about detail or appId, and the default-to-active-session behavior it mentions is already in the schema.

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?

States a specific verb (Diagnose) and resource (a session), then enumerates exactly what is inspected: device state via adb, Appium server reachability, session liveness, app state/foreground, ANR dialog. That is far more specific than a title restatement, though it never names how it differs from siblings like appium_diagnose or appium_session_management.

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?

Gives a clear condition for the mutating path: recover=true applies only to a recoverable failure (dead session or driver), and it states exclusions — cloud and attached sessions are not replaced. What's missing is routing guidance against the obvious alternatives (appium_diagnose, appium_session_management) for the non-recovery case.

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