Skip to main content
Glama
SSH/SFTP MCP Server

SSH/SFTP MCP Server

by veithly

ssh_connect

Establish an SSH connection to a remote server and return a session ID for running commands or SFTP operations. Provide host and username, with optional port, password, or private key.

Instructions

Establish an SSH connection to a remote server. Returns a session ID for subsequent operations.

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": {
      "host": "<host>",
      "username": "<username>"
    },
    "name": "ssh_connect"
  }
}

Input Schema

NameRequiredDescriptionDefault
hostYesSSH server hostname or IP address
portNoSSH server port (default: 22)
timeoutNoConnection timeout in milliseconds
passwordNoSSH password (for password authentication)
usernameYesSSH username
privateKeyNoPrivate key content or file path (for key authentication)
privateKeyPassphraseNoPassphrase for encrypted private key

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.3/5.0
Behavior2/5

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

With no annotations, the description carries full burden but only states it establishes a connection and returns a session ID. It omits behavioral details such as authentication order, error handling, network requirements, or potential side effects.

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 sentences, completely front-loaded with the core function and outcome. Every word is essential and there is no filler.

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?

The description mentions the key outcome (session ID for subsequent operations) but lacks details on authentication methods, timeout behavior, and what happens on failure. Given no output schema or annotations, it provides only minimal context for a complex tool.

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 description does not need to add parameter details. It correctly adds no redundant information, maintaining the baseline score of 3.

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 the tool's purpose: establish an SSH connection and return a session ID. It uses a specific verb ('Establish') and resource ('SSH connection'), and distinguishes itself from sibling tools like ssh_connect_by_id and sftp operations.

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 is provided on when to use this tool versus alternatives (e.g., ssh_connect_by_id) or prerequisites. It does not mention that this tool is typically the first step for subsequent SSH operations like ssh_exec.

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