Run a command (sync, or detach:true)
Run a shell command on a node. Synchronous (default): returns {exit_code, stdout, stderr, truncated}, budgeted by timeout (default and ceiling 60s here; nothing streams mid-call, and the HTTP door honors up to 300s). At the deadline the command is killed and the error carries the captured tail - only as good as your flushing (stdout is block-buffered off-tty: python -u / PYTHONUNBUFFERED=1); anything longer belongs in detach:true, whose log survives. Detached: returns {command_id, log_path} immediately; poll get_command for output and the exit code, kill_command to stop it. restart:"on-failure" respawns a detached command on nonzero exit (backoff, same log, then crash_loop; the node bills throughout). Write your verdict as JSON to $GMN_RESULT_PATH (injected) and it comes back on the status call. SECRETS GO IN env, NEVER THE COMMAND STRING: command lines are recorded (unless your org's retention policy declines it), env values ride only to the process (never recorded, names-only echo, redacted from logs); use short-lived, minimally scoped tokens and treat them as burned. Write files with the write_file tool. The tmux contract: files under ~ survive stop_node and wake; processes don't - a detached command dies with the container (it ends lost, no exit_code, no result; its log survives) - let a needed verdict reach an exit_code on get_command first. Push results out from inside the node before stopping. Calling this on a stopped node wakes it (billing starts when it's ready): you may get status "queued" (poll get_node, then re-call) or "waking" (re-call shortly); on_wake: true (detached, with max_duration_minutes) instead registers it to start the moment the node is ready. NEVER a sleep keepalive: "keep this node awake across turns" is hold_node - same node time, no command slot, no fake work on your mission page. The work lands on the node's mission automatically; pass mission: "<name>" only to attribute it elsewhere (a node reused under a new investigation).
Request
- Base URL: https://autoresearch.sfcompute.com
- URL: https://autoresearch.sfcompute.com/preview/nodes/{name}/commands
- Auth: HTTP bearer
Path parameters
Node name (from list_nodes).
Query parameters
Act in this workspace (its slug). Omitted: the token's bound workspace, then the organization's default. Never ambient - there is no switch-workspace mutation on this door.
Request body
Response
The capability's JSON result.
Changes
No recorded changes to this operation across all 1 revision of this API.