Appearance
openclaw nodes
管理配对节点(设备)并调用节点能力。
相关文档:
- 节点概览:Nodes
- 摄像头:Camera nodes
- 图片:Image nodes
通用选项:
--url、--token、--timeout、--json
常用命令
bash
openclaw nodes list
openclaw nodes list --connected
openclaw nodes list --last-connected 24h
openclaw nodes pending
openclaw nodes approve <requestId>
openclaw nodes status
openclaw nodes status --connected
openclaw nodes status --last-connected 24hnodes list 打印待处理/已配对的节点表格。已配对行包含最近的连接时间(Last Connect)。 使用 --connected 只显示当前已连接的节点。使用 --last-connected <duration> 过滤在指定时间内连接过的节点(例如 24h、7d)。
调用 / 运行
bash
openclaw nodes invoke --node <id|name|ip> --command <command> --params <json>
openclaw nodes run --node <id|name|ip> <command...>
openclaw nodes run --raw "git status"
openclaw 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>:环境变量覆盖(可重复)。注意:节点主机忽略PATH覆盖(tools.exec.pathPrepend不适用于节点主机)。--command-timeout <ms>:命令超时。--invoke-timeout <ms>:节点调用超时(默认30000)。--needs-screen-recording:要求屏幕录制权限。--raw <command>:运行 shell 字符串(/bin/sh -lc或cmd.exe /c)。 在 Windows 节点主机的允许列表模式下,cmd.exe /cshell 包装运行需要审批(仅允许列表条目不会自动允许包装形式)。--agent <id>:agent 范围的审批/允许列表(默认为已配置的 agent)。--ask <off|on-miss|always>、--security <deny|allowlist|full>:覆盖选项。
小技巧:配合
nodes run --raw和nodes camera snap,你的龙虾就能在家里的树莓派或 NAS 上执行脚本、还能顺手拍张照片确认机房状态——远程运维更省心。