SSH Connect
ssh_connectOpen an SSH connection to a remote server, using ~/.ssh/config aliases or explicit host details with password, private key, or agent authentication.
Instructions
Establish an SSH connection to a remote server. Reads ~/.ssh/config on every call for host aliases, identity files, ports, and usernames. Supports password, private key, and SSH agent authentication. Host keys are accepted on first use (TOFU) — no strict checking.
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>"
},
"name": "ssh_connect"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | Yes | Hostname, IP address, or SSH config alias to connect to | |
| port | No | SSH port (overrides SSH config, default 22) | |
| password | No | Password for authentication | |
| useAgent | No | Use SSH agent for authentication (default: true if no password/key provided and SSH_AUTH_SOCK is set) | |
| username | No | SSH username (overrides SSH config) | |
| passphrase | No | Passphrase for the private key | |
| connectionId | No | Custom identifier for this connection (default: host value). Use to manage multiple connections. | |
| connectTimeout | No | Connection timeout in milliseconds covering both TCP connect and SSH handshake (default 20000) | |
| privateKeyPath | No | Path to private key file (e.g. ~/.ssh/id_ed25519) |