Skip to main content
Glama

List Webview Pages

webview_pages
Read-only

Discover debuggable webview pages in an Android app: automatically forwards a local port, queries /json/list, and returns type:page targets for CDP inspection.

Instructions

列出目标 App webview 的调试目标(/json/list,自动 adb forward),确认 type:page 页面。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
portNo本地转发端口,默认 9222
deviceYes目标设备 serial(同 mobile_list_available_devices 的 id)
packageNameYesApp 包名(其 webview 被调试)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.1

TDQS

A3.8/5.0
Behavior4/5

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

Beyond the readOnlyHint annotation, the description adds genuine behavioral detail: it uses the /json/list endpoint, automatically performs an adb forward (a side effect on local port forwarding), and filters targets to type:page. These details are consistent with readOnlyHint=true and give the agent useful expectations about mechanism and scope.

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?

A single dense sentence that front-loads the primary action and packs in the endpoint, the auto-forward behavior, and the page-type filter. All information earns its place, though the mechanism details could arguably have followed the core purpose rather than being embedded mid-sentence.

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?

The tool is simple (3 params, no output schema) and the description covers what it does and its mechanism. However, with no output schema, the description never explains what the returned list contains (e.g., whether webSocketDebuggerUrl, title, or url fields are present) or how results feed into webview_connect, leaving a meaningful gap.

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 100%, so the schema already documents device, packageName, and the optional port with its default of 9222. The description reinforces that packageName refers to the app whose webview is being debugged, but adds little meaning beyond the schema, making the baseline of 3 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?

The description states a specific verb and resource: listing the debugging targets of a target app's webview, via the /json/list endpoint, and filtering to type:page targets. This clearly differentiates it from its webview_* siblings, all of which perform actions (connect, evaluate, screenshot) rather than discovery.

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

Usage Guidelines3/5

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

Usage is implied but not explicit: the tool is clearly a discovery step that would naturally precede webview_connect or webview_evaluate, and the '确认 type:page' phrase implies it filters out non-page targets. However, it never says 'use this before connecting' or names alternatives, leaving the agent to infer when this tool is the right choice.

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