`moltbot nodes`
适用范围
使用本页面当:
- 正在管理已配对的节点(相机、屏幕、画布)
- 需要批准请求或调用节点命令
管理已配对的节点(设备)并调用节点能力。
相关:
常用选项:
--url、--token、--timeout、--json
常用命令
moltbot nodes list
moltbot nodes list --connected
moltbot nodes list --last-connected 24h
moltbot nodes pending
moltbot nodes approve <requestId>
moltbot nodes status
moltbot nodes status --connected
moltbot nodes status --last-connected 24hnodes list 打印待处理/已配对的表格。已配对的行包含最近的连接时间(最后连接)。
使用 --connected 仅显示当前连接的节点。使用 --last-connected <duration> 过滤
在持续时间内连接的节点(例如 24h、7d)。
调用/运行
moltbot nodes invoke --node <id|name|ip> --command <command> --params <json>
moltbot nodes run --node <id|name|ip> <command...>
moltbot nodes run --raw "git status"
moltbot nodes run --agent main --node <id|name|ip> --raw "git status"调用标志:
--params <json>: JSON 对象字符串(默认{})。--invoke-timeout <ms>: 节点调用超时(默认15000)。--idempotency-key <key>: 可选的幂等密钥。
Exec 风格默认值
nodes run 镜像模型的 exec 行为(默认值 + 批准):
- 读取
tools.exec.*(加上agents.list[].tools.exec.*覆盖)。 - 在调用
system.run之前使用 exec 批准(exec.approval.request)。 - 当设置了
tools.exec.node时,可以省略--node。 - 需要一个通告
system.run的节点(macOS 伴侣应用或无头节点主机)。
标志:
--cwd <path>: 工作目录。--env <key=val>: 环境覆盖(可重复)。--command-timeout <ms>: 命令超时。--invoke-timeout <ms>: 节点调用超时(默认30000)。--needs-screen-recording: 需要屏幕录制权限。--raw <command>: 运行 shell 字符串(/bin/sh -lc或cmd.exe /c)。--agent <id>: agent 范围的批准/允许列表(默认为配置的 agent)。--ask <off|on-miss|always>、--security <deny|allowlist|full>: 覆盖。