#I want one agent for one dicord channel

1 messages · Page 1 of 1 (latest)

vestal cosmos
#

I want one agent for one dicord channel

fathom driftBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> âś… Mark Solution

stoic fieldBOT
#

If you mean “separate memory/context per Discord channel”: you already get that by default — Discord guild channels use separate session keys (so #general and #help won’t share context).

If you mean “a different agent (different workspace/system prompt/model/tools) for exactly one Discord channel”: use multi-agent + bindings, and (optionally) a guild channel allowlist so the bot won’t respond anywhere else.

1) Route one Discord channel → one agent (bindings)

Docs: https://docs.openclaw.ai/channels/channel-routing.md

{
  agents: {
    list: [
      { id: "main", default: true, workspace: "~/.openclaw/workspace-main" },
      { id: "support", workspace: "~/.openclaw/workspace-support" }
    ]
  },
#
  bindings: [
    {
      agentId: "support",
      match: {
        channel: "discord",
        peer: { kind: "channel", id: "YOUR_CHANNEL_ID" }
      }
    }
  ]
}

(Threads inherit from the parent channel automatically.)

2) (Optional but recommended) Make the bot only respond in that one channel

Docs: https://docs.openclaw.ai/channels/discord.md (see “Guild policy”)

#
{
  channels: {
    discord: {
      groupPolicy: "allowlist",
      guilds: {
        "YOUR_GUILD_ID": {
          requireMention: false,
          channels: {
            "YOUR_CHANNEL_ID": { allow: true }
          }
        }
      }
    }
  }
}
#

After changing config: restart the gateway.

If you tell me your Guild ID + Channel ID (and your openclaw --version), I can sanity-check the exact shape for your setup.

vestal cosmos
#

openclaw version : OpenClaw 2026.2.26 (bc50708) — fro channel and guild just put placeholder, do 3 different agents

stoic fieldBOT
#

Got it — on 2026.2.26 the clean way is:

  1. allowlist only the channels you want the bot to answer in (Discord guild policy)
  2. route each channel to a different agent (bindings)

Here’s a 3-agents / 3-channels config with placeholders:

Docs:

{
  agents: {
    list: [
      { id: "agent1", name: "Agent 1", workspace: "~/.openclaw/ws-agent1" },
#
      { id: "agent2", name: "Agent 2", workspace: "~/.openclaw/ws-agent2" },
      { id: "agent3", name: "Agent 3", workspace: "~/.openclaw/ws-agent3" },

      // optional: default fallback if something doesn't match
      { id: "main", name: "Main", workspace: "~/.openclaw/ws-main", default: true },
    ],
  },

  // 1) Discord: only allow this guild + only these channels
  channels: {
    discord: {
      groupPolicy: "allowlist",
      guilds: {
        "YOUR_GUILD_ID": {
          requireMention: false, // set true if you want "only when mentioned"
#
          channels: {
            "CHANNEL_ID_1": { allow: true },
            "CHANNEL_ID_2": { allow: true },
            "CHANNEL_ID_3": { allow: true },
          },
        },
      },
    },
  },

  // 2) Route each channel to its own agent
  bindings: [
    {
      agentId: "agent1",
      match: { channel: "discord", peer: { kind: "channel", id: "CHANNEL_ID_1" } },