Skip to main content
Glama

ssh_disconnect

Terminate SSH connections to remote servers managed through the mcpHydroSSH server, freeing resources and ending sessions when remote work is complete.

Instructions

Disconnect from an SSH server

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
connectionIdNoConnection ID (optional, disconnects most recent if not provided)

Implementation Reference

  • The handler implementation for the 'ssh_disconnect' tool, which uses sshManager.disconnect(connectionId) to perform the action.
    case 'ssh_disconnect': {
      const connectionId = args.connectionId as string | undefined;
      try {
        sshManager.disconnect(connectionId);
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify({ success: true }, null, 2),
            },
          ],
        };
      } catch (err: unknown) {
        return {
          content: [
            {
              type: 'text',
  • The tool registration and schema definition for 'ssh_disconnect'.
    {
      name: 'ssh_disconnect',
      description: 'Disconnect from an SSH server',
      inputSchema: {
        type: 'object',
        properties: {
          connectionId: {
            type: 'string',
            description: 'Connection ID (optional, disconnects most recent if not provided)',
          },
        },
        required: [],
      },
Behavior2/5

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

With no annotations provided, the description carries full burden but discloses nothing about side effects. It omits whether this gracefully terminates ongoing commands, affects other connections, or cleanup behavior (e.g., does it also remove from ssh_get_status?).

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?

Extremely terse at four words. While no words are wasted, the extreme brevity contributes to the lack of behavioral context and guidelines. A single additional sentence about lifecycle or defaults would improve utility without sacrificing clarity.

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?

Minimum viable for a simple lifecycle operation. However, given the complexity of the SSH tool ecosystem (9 siblings including exec and connect), the description should clarify session lifecycle implications—specifically whether disconnecting affects running exec commands or server configuration persistence.

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 coverage is 100%, so the baseline is 3. The description adds no parameter details, but the schema adequately documents the optional connectionId behavior without needing expansion in the description.

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 uses a specific verb (disconnect) and resource (SSH server), making the basic purpose clear. However, it misses the opportunity to distinguish from sibling 'ssh_remove_server' (which deletes configuration) by clarifying this terminates active sessions.

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?

No guidance on when to use versus alternatives, or prerequisites (e.g., 'use after completing ssh_exec operations'). The optional nature of the connectionId parameter and its default behavior (most recent) is left entirely to the schema.

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/hydroCoderClaud/mcpHydroSSH'

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