Skip to main content
Glama
ifindv
by ifindv

ssh_disconnect

Idempotent

Terminate an active SSH connection by providing the session ID. Frees server resources and confirms disconnection.

Instructions

Close an SSH connection session.

This tool terminates an SSH session and frees associated resources.

Args: params (DisconnectInput): Validated input parameters containing: - session_id (str): SSH session identifier to close

Returns: str: Disconnection confirmation

Examples: - Use when: "Close SSH connection to server" -> params with session_id="admin@192.168.1.100:22" - Use when: "Done working with server, disconnect" -> params with session_id (from ssh_connect) - Don't use when: Session doesn't exist (ssh_status will show this) - Don't use when: Need to continue working with the server

Error Handling: - Returns "Error: Session not found" if session_id is invalid - Returns success even if session was already closed

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Annotations indicate idempotentHint=true and not destructive. Description adds that it terminates and frees resources, and returns success even if already closed, aligning with annotations. Slight gap: doesn't detail what 'frees associated resources' means, but overall good.

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?

Concise with clear sections (overview, args, returns, examples, error handling). Every sentence adds value, and the structure is front-loaded with the core purpose.

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?

For a simple one-parameter tool, the description covers purpose, usage, error handling, idempotency, and return format. Output schema exists but description adequately summarizes the return value.

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?

The only parameter, session_id, has a description in the schema ('SSH session identifier to close') which is repeated verbatim in the description. No additional semantics or constraints are provided 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?

The description clearly states 'Close an SSH connection session' and elaborates that it terminates an SSH session and frees resources. It uses specific verb-resource pairing and distinguishes from sibling tools like ssh_connect, ssh_execute, etc.

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

Usage Guidelines5/5

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

Provides explicit when-to-use and when-not-to-use examples, such as 'Use when: Close SSH connection to server' and 'Don't use when: Session doesn't exist' or 'Need to continue working with the server.' Also covers error handling and idempotency.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ifindv/ssh-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server