destructive-command
Runs shell commands that require client-side user approval, handling destructive or privileged operations refused by run-command with APPROVAL_VIA_TOOL.
Instructions
Execute a shell command on a profile with approvalPolicy = "client-tool", where calling this tool is the approval: the MCP client asks the user before the call runs. Use it when run-command refuses a destructive or privileged command with APPROVAL_VIA_TOOL; it takes the same arguments. On a profile with any other approvalPolicy it runs nothing and points back at run-command (CLIENT_TOOL_ONLY). Single-line only: a command containing a line break is refused, so upload a multi-line script with sftp-upload and run it by path.
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": "destructive-command"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tty | No | Allocate a pseudo-terminal | |
| command | Yes | Shell command to execute | |
| profile | No | Profile name | |
| session | No | Run in an existing interactive session (stateful) |