Run command in sandbox
sandbox_execRun PowerShell or CMD commands in an elevated Windows sandbox session and return stdout, stderr, and exit code; use for short-lived administrative tasks, not GUI or long-running apps.
Instructions
Run a command in the sandbox (elevated admin user session) and wait for it. Returns stdout, stderr and exit code. Use sandbox_launch for GUI apps or anything long-running. The sandbox has Windows PowerShell 5.1 and .NET Framework 4, but no Store apps (no Notepad, Calculator, Terminal) and no winget.
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": "sandbox_exec"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | ||
| shell | No | Default powershell (Windows PowerShell 5.1). | |
| command | Yes | ||
| timeoutSec | No | Default 120. The process tree is killed on timeout. |