execute
Execute shell commands on remote servers via SSH. Specify the server and command; optionally set timeout, working directory, or dry-run preview.
Instructions
Execute a shell command on a single SSH server.
Args:
server: Server name (e.g. 'web-prod-01'). Must match a configured server.
Use list_servers to see available servers.
command: Shell command to execute on the remote server (exactly as it
would be typed at a bash prompt).
timeout: Command timeout in seconds. Default 30. Range 1–3600.
working_dir: Absolute remote directory to cd into before running the
command. Uses the server's default_dir from servers.toml
if omitted, or the SSH login directory if neither is set.
force: If True, bypass the dangerous-command detection regex. Use only
for audited bulk operations — the block list catches rm -rf /,
mkfs, dd-to-disk, chmod 777 /, and fork bombs. Default False.
dry_run: If True, do NOT connect or execute. Return a preview describing
what would run (server, command, working_dir, timeout, force).
Dangerous-command detection still runs so rejection can be
previewed. Useful for LLM plans that want to validate intent
before committing. Default False.
Returns:
Formatted command execution result with stdout, stderr, and exit code.
Long output is truncated at max_output_bytes (default 50 KiB).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | ||
| server | Yes | ||
| command | Yes | ||
| dry_run | No | ||
| timeout | No | ||
| working_dir | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |