Skip to main content
Glama

Robot Actions — Remote Device Control

Android DevTools close page

android_devtools_close_page
Idempotent

Close a debuggable tab/page on the device by pageId (CDP /json/close). Use to clean up stale tabs that accumulate across sessions and clutter android_devtools_list_pages. Get the pageId from android_devtools_list_pages. Returns { closed, pageId } — closed:false if no such page.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
udidYesDevice serial number (UDID)
pageIdYesTarget page id (from android_devtools_list_pages) to close
socketNoAbstract unix socket name (default: chrome_devtools_remote)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations cover the safety profile (readOnlyHint=false, idempotentHint=true, destructiveHint=false); the description adds value on top by disclosing the return shape ({ closed, pageId }) and the no-op outcome (closed:false if no such page). It doesn't mention auth or socket behavior, but the annotations already do the heavy lifting.

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?

Three tight sentences: action first, then purpose/routing, then return contract. No filler, nothing repeated from the schema.

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?

With no output schema, the description supplies the return contract itself, plus the pageId prerequisite and cleanup rationale. Nothing an agent needs to invoke this correctly is missing.

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% and the schema already documents udid, pageId (including its origin in android_devtools_list_pages), and socket. The description reinforces the pageId source but adds no syntax or format detail beyond the schema, so baseline 3 applies.

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 ('Close a debuggable tab/page on the device by pageId') plus the underlying mechanism (CDP /json/close). It is clearly distinguishable from android_devtools_list_pages and the other android_devtools_* siblings.

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 says when to use it ('clean up stale tabs that accumulate across sessions and clutter android_devtools_list_pages') and where to get the required pageId. It does not name a when-not condition or an alternative close path, but none is needed here.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources