execute_local_command
Executes shell commands locally and returns stdout, stderr, and exit code, providing a direct way to inspect and automate system tasks.
Instructions
[DISABLED - set LNMCP_ENABLE_EXEC=1 to enable] Execute a shell command on the local machine. Returns stdout, stderr, and exit code.
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": {
"command": "<command>"
},
"name": "execute_local_command"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | Working directory for command execution (optional) | |
| env | No | Additional environment variables (optional) | |
| shell | No | Use shell interpretation (default: true) | |
| command | Yes | Shell command to execute | |
| timeout | No | Command timeout in seconds (default: 30) |