Skip to main content
Glama

server_session_close

Terminate and clean up an SSH session using its session ID to release resources and prevent orphaned remote connections.

Instructions

Terminate and clean up an SSH session.

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": {
      "session_id": "<session_id>"
    },
    "name": "server_session_close"
  }
}

Input Schema

NameRequiredDescriptionDefault
session_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.7/5.0
Behavior2/5

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

With no annotations supplied, the description carries the full disclosure burden and falls short: it does not say whether the close is idempotent, whether an invalid or already-closed session_id errors or succeeds silently, whether in-flight commands are interrupted, or what the response contains. 'Clean up' hints at resource release but never specifies what is destroyed, which is the key behavioral fact for a teardown tool.

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 sentence with zero filler, and the destructive verb is front-loaded. It is efficient, though its brevity is partly the source of the missing behavioral detail rather than purely a virtue.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a session-terminating mutation with no annotations, no output schema, and an undocumented parameter, the definition is too thin — an agent cannot tell whether closing an unknown session raises an error, what state the server is left in, or whether cleanup is guaranteed. Those are exactly the facts a teardown tool's description should supply.

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% and the description adds nothing about the single parameter — it does not state that session_id must be an active session returned by server_session_start/server_session_list, nor what happens if it is stale. The parameter is guessable from its name, but the description does not compensate for the schema's total lack of documentation.

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 pairs a specific verb ('Terminate and clean up') with a specific resource ('an SSH session'), so the agent knows exactly what action is performed. It is distinguishable from siblings like server_session_start or server_session_read by the operation word alone, though the description 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 Guidelines2/5

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

There is no guidance on when to call this versus alternatives such as server_session_list or server_session_write, nor any precondition such as requiring the session to be idle or owned by the caller. The agent must infer from the name alone that this is the teardown step in a session lifecycle.

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