Skip to main content
Glama

close-agent-pane

DestructiveIdempotent

Close a managed viewer pane after an agent completes, fails, or is cancelled without terminating the agent. Idempotent, and the last agent to close also closes the workspace.

Instructions

After the client observes agent completion, failure or cancellation, close only its managed viewer session. Does not terminate the agent. Last agent closes the workspace. Idempotent.

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": {
      "workspaceId": "<workspaceId>",
      "agentId": "<agentId>",
      "status": "<status>"
    },
    "name": "close-agent-pane"
  }
}

Input Schema

NameRequiredDescriptionDefault
statusYes
agentIdYes
delayMsNo
exitCodeNo
workspaceIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false and idempotentHint=true, so 'Idempotent' in the description is largely redundant. The description still adds genuine value beyond the annotations: it discloses that only the viewer session is closed, that the agent process survives, and that the final pane close cascades to the workspace.

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?

Four short sentences, front-loaded with the trigger condition, no filler. The scope limits and cascade behavior are each stated once.

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?

No output schema exists, so the description should carry more of the return/effect story, and the unexplained exitCode and delayMs parameters are a real gap for a destructive mutation. The lifecycle effects it does describe (session-only close, workspace cascade, idempotency) are the most important ones, which keeps this at an adequate level.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across five parameters, and the description mentions none of them. It never explains what status, exitCode, or delayMs are for — particularly non-obvious for a close operation — leaving the agent to infer semantics from bare names and types.

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 ... its managed viewer session') and immediately bounds the scope: 'Does not terminate the agent.' It also implicitly separates itself from close-workspace by noting that the last agent closes the workspace, so an agent can tell the two apart without opening either schema.

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 precondition for use: 'After the client observes agent completion, failure or cancellation.' The exclusion 'Does not terminate the agent' implies termination is handled elsewhere, but no sibling is named explicitly and no 'when not to use' rule is spelled out.

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