Run a command as a managed, log-captured execution
execution_runRun a command as a subprocess with automatic log correlation ID injection, capturing stdout/stderr as logs for debugging scripts and test runs.
Instructions
Spawns command as a subprocess with LOG_PROBE_URL/LOG_PROBE_EXECUTION_ID/LOG_PROBE_SESSION_ID auto-injected into its environment, so any instrumentation you've added can POST straight to the ingestion server without you wiring the correlation IDs by hand. Stdout/stderr are also captured line-by-line as logs (stderr as level=error), merged with any HTTP-posted structured logs in execution_get_logs. Waits for the process to exit (or timeoutMs to elapse). Requires probe_server_start to have been called first. Best for scripts, one-off repros, and test runs (e.g. running a flaky test N times); for long-running services, use execution_create instead.
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": {
"sessionId": "<sessionId>",
"command": "<command>"
},
"name": "execution_run"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | ||
| env | No | Additional env vars, merged over the inherited environment. | |
| args | No | ||
| label | No | ||
| command | Yes | Executable to run, e.g. "npm" or "node". | |
| sessionId | Yes | ||
| timeoutMs | No | Default 120000 (2 minutes). |