Run a command in a service
RunServiceCommandRuns a command in a running service's container, like docker exec; returns the exit code and the output's end once it exits or the timeout kills it. Over a bound on command, stdin or timeout = refused (named). Cannot start = exit 127 or 126, Docker's error in stdout. Untrusted output.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "RunServiceCommand"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| stdin | No | Written to stdin, then closed. | |
| command | No | E.g. ["psql", "-c", "select 1"]; a shell line: ["sh", "-c", "ls | head"]. | |
| service | No | ||
| workspace | No | The workspace: its id or name (ListWorkspaces). Omit when the account has one. | |
| project_id | No | ||
| run_as_user | No | Empty = the container's. "root" can install packages. | |
| timeout_seconds | No | 0 = default. Kills the main process only. Over ~50 may outlast your client: background long jobs. | |
| working_directory | No | Empty = the container's. |