← 返回
未分类 中文

OpenClaw Add Agent

Add a new agent to OpenClaw configuration. Use when user wants to add a new Telegram bot agent to OpenClaw. Triggers: add agent, new agent, bind telegram.
向OpenClaw配置添加新代理,用于添加Telegram机器人代理。触发词:add agent、new agent、bind telegram。
gaoxiaowei2117 gaoxiaowei2117 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 271
下载
💾 0
安装
1
版本
#latest

概述

Add Agent to OpenClaw

Workflow

Step 1: Collect Agent Info

Required info from user:

  • Bot token: Telegram bot token (format: 123456789:ABCdef...)
  • Agent ID: Unique identifier (e.g., translator, customer_support)
  • Purpose/Name: Display name (optional, defaults to agent ID)
  • Allow users: Telegram user IDs that can access this bot (default: same as existing agents)

Step 2: Update openclaw.json

Edit /home/xgao/.openclaw/openclaw.json:

A. Add agent to agents.list:

{
  "id": "<agent_id>",
  "name": "<name>",
  "workspace": "/home/xgao/clawd-workspace/<agent_id>"
}

B. Add binding:

{
  "agentId": "<agent_id>",
  "match": {
    "channel": "telegram",
    "accountId": "<agent_id>"
  }
}

C. Add telegram account:

"<agent_id>": {
  "enabled": true,
  "dmPolicy": "allowlist",
  "botToken": "<token>",
  "allowFrom": [<user_ids>],
  "groupPolicy": "allowlist",
  "streaming": "partial"
}

Step 3: Create Workspace Directory

mkdir -p /home/xgao/clawd-workspace/<agent_id>

Step 4: Ask About Memory Isolation

Ask user: "是否需要独立的memory?"

  • Yes → Each agent already has independent workspace, memory is automatically isolated
  • No → Share workspace (not recommended)

Step 5: Restart OpenClaw

Inform user to restart: openclaw restart

Minimal Config Example

For a simple translator bot:

// agents.list
{ "id": "translator", "name": "translator", "workspace": "/home/xgao/clawd-workspace/translator" }

// bindings
{ "agentId": "translator", "match": { "channel": "telegram", "accountId": "translator" } }

// channels.telegram.accounts
"translator": { "enabled": true, "dmPolicy": "allowlist", "botToken": "8223784004:AAE-...", "allowFrom": ["8538882690"], "groupPolicy": "allowlist", "streaming": "partial" }

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-08 03:15 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-agent

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,412 📥 325,315
ai-agent

Skill Vetter

spclaudehome
AI智能体技能安全预审工具。安装ClawdHub、GitHub等来源技能前,检查风险信号、权限范围及可疑模式。
★ 1,243 📥 271,442
ai-agent

Find Skills

guipi888
场景驱动+关键词双模式技能发现工具。当用户用自然语言描述场景/需求(如"我想做一个海报""帮我分析股票"),或明确说"安装技能/find skills/找个skill"时,自动从官方内置、本地已安装、SkillHub、虾评、GitHub、C
★ 1,494 📥 558,976