Skip to main content
Glama
Chrome DevTools Debug MCP Server

Chrome DevTools Debug MCP Server

by m4eba

close_target

Closes a Chrome page or tab by its target ID, letting you clean up browser targets during debugging. Fails on the currently attached target, preventing accidental loss of the active session.

Instructions

Close a target (page/tab) by its ID. Cannot close the currently attached target.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "targetId": "<targetId>"
    },
    "name": "close_target"
  }
}

Input Schema

NameRequiredDescriptionDefault
targetIdYesTarget ID of the page/tab to close

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.1

TDQS

A3.8/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden, and it does disclose one important constraint about the attached target. It does not state what happens on failure (throw vs. error result), whether closing is permanent, or what becomes the active target afterwards, which are material gaps for a destructive-style operation with zero annotation coverage.

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?

Two short sentences, no filler, with the core action front-loaded and the constraint appended. Every clause earns its place.

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 one-parameter tool with a fully documented schema and no output schema, the description covers the action and the one gotcha that would cause a real failure. Only the post-close state and error behavior are left to inference, which is a minor omission at this complexity level.

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 single targetId parameter is already documented as 'Target ID of the page/tab to close'. The phrase 'by its ID' in the description restates rather than extends the schema, so the baseline 3 for a well-covered schema applies.

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?

The description gives a specific verb plus resource ('Close a target') and immediately disambiguates the jargon by glossing target as 'page/tab', which is the key detail an agent needs. It is clearly distinct from siblings like create_target or activate_target, though it never names those alternatives explicitly.

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?

It supplies a real pre-condition/exclusion: the currently attached target cannot be closed, which is exactly the kind of usage constraint that prevents a failed call. It stops short of telling the agent what to do instead (e.g., switch to another target first), so it is clear context plus one exclusion rather than full when/when-not routing.

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

Deploy Server

Other Tools