ssh_execute
Execute shell commands on remote hosts over SSH, auto-creating connections to simplify remote device management.
Instructions
[DISABLED - set LNMCP_ENABLE_SSH_EXEC=1 to enable] Execute a command on a remote host via SSH. Will create connection if not exists.
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>",
"command": "<command>"
},
"name": "ssh_execute"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | Yes | IP address or hostname | |
| port | No | SSH port (default: 22) | |
| command | Yes | Command to execute on remote host | |
| timeout | No | Command timeout in seconds (default: 30) | |
| password | No | SSH password (optional if using key or existing connection) | |
| username | Yes | SSH username | |
| key_filename | No | Path to SSH private key file (optional) |