$npx -y skills add SafeAI-Lab-X/ClawKeeper --skill discordDiscord ops via the message tool (channel=discord).
| 1 | # Discord (Via `message`) |
| 2 | |
| 3 | Use the `message` tool. No provider-specific `discord` tool exposed to the agent. |
| 4 | |
| 5 | ## Musts |
| 6 | |
| 7 | - Always: `channel: "discord"`. |
| 8 | - Respect gating: `channels.discord.actions.*` (some default off: `roles`, `moderation`, `presence`, `channels`). |
| 9 | - Prefer explicit ids: `guildId`, `channelId`, `messageId`, `userId`. |
| 10 | - Multi-account: optional `accountId`. |
| 11 | |
| 12 | ## Guidelines |
| 13 | |
| 14 | - Avoid Markdown tables in outbound Discord messages. |
| 15 | - Mention users as `<@USER_ID>`. |
| 16 | - Prefer Discord components v2 (`components`) for rich UI; use legacy `embeds` only when you must. |
| 17 | |
| 18 | ## Targets |
| 19 | |
| 20 | - Send-like actions: `to: "channel:<id>"` or `to: "user:<id>"`. |
| 21 | - Message-specific actions: `channelId: "<id>"` (or `to`) + `messageId: "<id>"`. |
| 22 | |
| 23 | ## Common Actions (Examples) |
| 24 | |
| 25 | Send message: |
| 26 | |
| 27 | ```json |
| 28 | { |
| 29 | "action": "send", |
| 30 | "channel": "discord", |
| 31 | "to": "channel:123", |
| 32 | "message": "hello", |
| 33 | "silent": true |
| 34 | } |
| 35 | ``` |
| 36 | |
| 37 | Send with media: |
| 38 | |
| 39 | ```json |
| 40 | { |
| 41 | "action": "send", |
| 42 | "channel": "discord", |
| 43 | "to": "channel:123", |
| 44 | "message": "see attachment", |
| 45 | "media": "file:///tmp/example.png" |
| 46 | } |
| 47 | ``` |
| 48 | |
| 49 | - Optional `silent: true` to suppress Discord notifications. |
| 50 | |
| 51 | Send with components v2 (recommended for rich UI): |
| 52 | |
| 53 | ```json |
| 54 | { |
| 55 | "action": "send", |
| 56 | "channel": "discord", |
| 57 | "to": "channel:123", |
| 58 | "message": "Status update", |
| 59 | "components": "[Carbon v2 components]" |
| 60 | } |
| 61 | ``` |
| 62 | |
| 63 | - `components` expects Carbon component instances (Container, TextDisplay, etc.) from JS/TS integrations. |
| 64 | - Do not combine `components` with `embeds` (Discord rejects v2 + embeds). |
| 65 | |
| 66 | Legacy embeds (not recommended): |
| 67 | |
| 68 | ```json |
| 69 | { |
| 70 | "action": "send", |
| 71 | "channel": "discord", |
| 72 | "to": "channel:123", |
| 73 | "message": "Status update", |
| 74 | "embeds": [{ "title": "Legacy", "description": "Embeds are legacy." }] |
| 75 | } |
| 76 | ``` |
| 77 | |
| 78 | - `embeds` are ignored when components v2 are present. |
| 79 | |
| 80 | React: |
| 81 | |
| 82 | ```json |
| 83 | { |
| 84 | "action": "react", |
| 85 | "channel": "discord", |
| 86 | "channelId": "123", |
| 87 | "messageId": "456", |
| 88 | "emoji": "✅" |
| 89 | } |
| 90 | ``` |
| 91 | |
| 92 | Read: |
| 93 | |
| 94 | ```json |
| 95 | { |
| 96 | "action": "read", |
| 97 | "channel": "discord", |
| 98 | "to": "channel:123", |
| 99 | "limit": 20 |
| 100 | } |
| 101 | ``` |
| 102 | |
| 103 | Edit / delete: |
| 104 | |
| 105 | ```json |
| 106 | { |
| 107 | "action": "edit", |
| 108 | "channel": "discord", |
| 109 | "channelId": "123", |
| 110 | "messageId": "456", |
| 111 | "message": "fixed typo" |
| 112 | } |
| 113 | ``` |
| 114 | |
| 115 | ```json |
| 116 | { |
| 117 | "action": "delete", |
| 118 | "channel": "discord", |
| 119 | "channelId": "123", |
| 120 | "messageId": "456" |
| 121 | } |
| 122 | ``` |
| 123 | |
| 124 | Poll: |
| 125 | |
| 126 | ```json |
| 127 | { |
| 128 | "action": "poll", |
| 129 | "channel": "discord", |
| 130 | "to": "channel:123", |
| 131 | "pollQuestion": "Lunch?", |
| 132 | "pollOption": ["Pizza", "Sushi", "Salad"], |
| 133 | "pollMulti": false, |
| 134 | "pollDurationHours": 24 |
| 135 | } |
| 136 | ``` |
| 137 | |
| 138 | Pins: |
| 139 | |
| 140 | ```json |
| 141 | { |
| 142 | "action": "pin", |
| 143 | "channel": "discord", |
| 144 | "channelId": "123", |
| 145 | "messageId": "456" |
| 146 | } |
| 147 | ``` |
| 148 | |
| 149 | Threads: |
| 150 | |
| 151 | ```json |
| 152 | { |
| 153 | "action": "thread-create", |
| 154 | "channel": "discord", |
| 155 | "channelId": "123", |
| 156 | "messageId": "456", |
| 157 | "threadName": "bug triage" |
| 158 | } |
| 159 | ``` |
| 160 | |
| 161 | Search: |
| 162 | |
| 163 | ```json |
| 164 | { |
| 165 | "action": "search", |
| 166 | "channel": "discord", |
| 167 | "guildId": "999", |
| 168 | "query": "release notes", |
| 169 | "channelIds": ["123", "456"], |
| 170 | "limit": 10 |
| 171 | } |
| 172 | ``` |
| 173 | |
| 174 | Presence (often gated): |
| 175 | |
| 176 | ```json |
| 177 | { |
| 178 | "action": "set-presence", |
| 179 | "channel": "discord", |
| 180 | "activityType": "playing", |
| 181 | "activityName": "with fire", |
| 182 | "status": "online" |
| 183 | } |
| 184 | ``` |
| 185 | |
| 186 | ## Writing Style (Discord) |
| 187 | |
| 188 | - Short, conversational, low ceremony. |
| 189 | - No markdown tables. |
| 190 | - Mention users as `<@USER_ID>`. |