plugin-ssh (1.1.0-dev.ca456637)
Installation
registry=npm install plugin-ssh@1.1.0-dev.ca456637"plugin-ssh": "1.1.0-dev.ca456637"About this package
SSH
SSH command execution, SFTP file operations and interactive terminal sessions (uses ssh2, decisions E-14/E-32)
- Package:
plugin-ssh - Author: Kai
- Version: 1.1.0
Credentials
| Key | Label | Type | Required | Default |
|---|---|---|---|---|
host |
Host | string | yes | – |
port |
Port | number | no | 22 |
user |
User | string | yes | – |
password |
Password | secret | no | – |
privateKey |
Private SSH key | secret (multiline) | no | – |
passphrase |
Key passphrase | secret | no | – |
Settings
| Key | Label | Type | Required | Default |
|---|---|---|---|---|
timeoutMs |
Timeout (ms) | number | no | 15000 |
sessionIdleMs |
Session idle timeout (ms, 0 = never) | number | no | 300000 |
maxSessions |
Max concurrent sessions | number | no | 8 |
maxBufferBytes |
Session output buffer (bytes) | number | no | 262144 |
sessionShell |
Default shell for sessions | string | no | bash -l |
execQuietMs |
Exec quiet period (ms) | number | no | 300 |
execTimeoutMs |
Exec timeout (ms) | number | no | 60000 |
Tools
| Tool | Description |
|---|---|
ssh_exec |
Runs a shell command on the SSH host and returns stdout, stderr and the exit code |
ssh_ping |
Connects to the SSH host and reports connection details (server banner) |
ssh_session_start |
Starts a persistent interactive SSH terminal session (PTY shell). Returns a sessionId; then use ssh_session_send to type input, ssh_session_read to stream the output, ssh_session_exec to run a command and wait for completion, ssh_session_close to end it. Sessions stay open until closed or idle for sessionIdleMs |
ssh_session_send |
Sends raw input to the session's terminal stdin (like typing into the terminal). Include a trailing newline ('\n' or '\r') to submit a line. Use after ssh_session_start |
ssh_session_read |
Streams the new output of a session since the last read. Blocks up to waitMs for more output (long-poll); set until to a marker string to wait until that text appears. Returns output, eof, hasMore and dropped |
ssh_session_exec |
Runs a command inside the session and waits until it finishes, returning the output. mode 'marker' (default) appends an internal completion marker and reports the exit code; mode 'quiet' returns after quietMs without new data (may return early for commands with pauses). Do not run two execs on the same session concurrently. Commands that terminate the shell (exit, logout) close the session (eof: true) and may not produce an exit code |
ssh_session_list |
Lists the open SSH sessions of this instance with metadata (session id, age, buffered bytes) - useful to recover sessions after losing context |
ssh_session_close |
Closes an SSH session (connection + shell) and returns the remaining buffered output |
ssh_sftp_list |
Lists a directory via SFTP |
ssh_sftp_read |
Reads a file via SFTP |
ssh_sftp_write |
Writes a file via SFTP (creates directories as needed) |
ssh_sftp_mkdir |
Creates a directory via SFTP (recursive) |
ssh_sftp_delete |
Deletes a file or directory via SFTP (recursive for directories) |
ssh_sftp_stat |
Returns stat information for a remote path |
Dependencies
Dependencies
| ID | Version |
|---|---|
| ssh2 | ^1.16.0 |
Keywords
mcp
mcp-plugin
ssh
sftp
remote
terminal
shell
Details
Assets (1)
Versions (3)
View all