feat: add discord guild wildcard defaults

This commit is contained in:
Peter Steinberger
2026-01-02 22:33:26 +01:00
parent 47f4f59692
commit fd32fc8d8d
6 changed files with 28 additions and 1 deletions

View File

@@ -208,6 +208,7 @@ Configure the Discord bot by setting the bot token and optional gating:
groupChannels: ["clawd-dm"] // optional group DM allowlist
},
guilds: {
"*": { requireMention: true }, // default per-guild mention gating
"123456789012345678": { // guild id (preferred) or slug
slug: "friends-of-clawd",
requireMention: false, // per-guild default
@@ -225,6 +226,7 @@ Configure the Discord bot by setting the bot token and optional gating:
Clawdis starts Discord only when a `discord` config section exists. The token is resolved from `DISCORD_BOT_TOKEN` or `discord.token` (unless `discord.enabled` is `false`). Use `user:<id>` (DM) or `channel:<id>` (guild channel) when specifying delivery targets for cron/CLI commands.
Guild slugs are lowercase with spaces replaced by `-`; channel keys use the slugged channel name (no leading `#`). Prefer guild ids as keys to avoid rename ambiguity.
Use `discord.guilds."*"` for default per-guild settings.
### `imessage` (imsg CLI)