openclaw agents
查看和管理所有已配置的 Agent 实例。
命令签名
bash
openclaw agents [子命令] [选项]子命令
| 子命令 | 说明 |
|---|---|
list | 列出所有已配置的 Agent(默认) |
选项
| 选项 | 类型 | 说明 |
|---|---|---|
--status <status> | string | 按状态过滤:running、stopped、error |
--format <format> | string | 输出格式:table(默认)、json、yaml |
--json | boolean | 等同于 --format json |
说明
openclaw agents 显示系统中所有已注册的 Agent,包括其运行状态、上线时间和关联渠道。在多 Agent 环境中,此命令是了解全局视图的入口。
输出格式
默认表格输出:
NAME STATUS UPTIME CHANNELS
default running 2h30m whatsapp, telegram
customer-support running 1h15m webchat
data-analyst stopped — —JSON 输出(--json):
json
{
"agents": [
{
"name": "default",
"status": "running",
"uptime": "2h30m",
"channels": ["whatsapp", "telegram"]
}
]
}示例
bash
# 列出所有 Agent
openclaw agents
# 仅显示运行中的 Agent
openclaw agents list --status running
# 以 JSON 格式输出
openclaw agents --json
# 过滤出错的 Agent
openclaw agents list --status error多 Agent 管理
在配置文件中定义多个 Agent:
yaml
agents:
default:
model: gpt-4
channels: [whatsapp, telegram]
customer-support:
model: gpt-4
channels: [webchat]使用 openclaw agent start --name <name> 启动指定 Agent。
另请参阅
openclaw agent— 管理单个 Agent 实例openclaw config— 配置管理openclaw channels— 渠道管理
