agentleFS
jholhewresjholhewres/devclaw-skills/skills/discord/SKILL.md

discord

Skill4 starsChanged 9 months agoMITView on GitHub

Discord integration — send messages via webhooks and bots

  • Sends data out

We split this skill into the rules it gives an agent

2 rules. 0 are common, 2 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 30 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use webhook URL for simple notifications.

    line 23
  2. Distinctive:

    Create an application, add a bot, copy the Bot Token

    line 37

“Common” is measured: kept by at least 6 in 10 of the 30 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Discord

Interact with Discord using webhooks or the Bot API.

Setup

  1. Check existing credentials:
    vault_get discord_webhook_url
    vault_get discord_bot_token
    Use webhook URL for simple notifications; use bot token for full Bot API (channels, messages, guilds).
  2. Webhook (easiest):
    • Go to Server Settings > Integrations > Webhooks in your Discord server
    • Click "New Webhook", name it, select channel
    • Copy the Webhook URL
    • Save to vault:
      vault_save discord_webhook_url "https://discord.com/api/webhooks/ID/TOKEN"
    The URL is auto-injected as $DISCORD_WEBHOOK_URL.
  3. Bot API (more features):The token is auto-injected as $DISCORD_BOT_TOKEN.

Send Messages (Webhook)

# Simple message
curl -s -X POST "$DISCORD_WEBHOOK_URL" \
  -H "Content-Type: application/json" \
  -d '{"content": "Hello from DevClaw!"}'

# With username and avatar override
curl -s -X POST "$DISCORD_WEBHOOK_URL" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "Custom message",
    "username": "DevClaw Bot",
    "avatar_url": "https://example.com/avatar.png"
  }'

# With embed (rich formatting)
curl -s -X POST "$DISCORD_WEBHOOK_URL" \
  -H "Content-Type: application/json" \
  -d '{
    "embeds": [{
      "title": "Notification",
      "description": "Something happened!",
      "color": 3447003,
      "fields": [
        {"name": "Status", "value": "Success", "inline": true},
        {"name": "Time", "value": "Now", "inline": true}
      ]
    }]
  }'

Bot API (More Features)

# Requires DISCORD_BOT_TOKEN (stored in vault)

# Send message to channel
curl -s -X POST "https://discord.com/api/v10/channels/CHANNEL_ID/messages" \
  -H "Authorization: Bot $DISCORD_BOT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"content": "Hello!"}'

# Get channel messages
curl -s "https://discord.com/api/v10/channels/CHANNEL_ID/messages?limit=10" \
  -H "Authorization: Bot $DISCORD_BOT_TOKEN" | jq '.[] | {author: .author.username, content}'

# List guilds (servers)
curl -s "https://discord.com/api/v10/users/@me/guilds" \
  -H "Authorization: Bot $DISCORD_BOT_TOKEN" | jq '.[] | {id, name}'

Embed Examples

# Status embed with color coding
curl -s -X POST "$DISCORD_WEBHOOK_URL" \
  -H "Content-Type: application/json" \
  -d '{
    "embeds": [{
      "title": "Deploy Status",
      "description": "Production deployment completed",
      "color": 3066993,
      "footer": {"text": "DevClaw Automation"}
    }]
  }'

# Colors: Red=15158332, Green=3066993, Blue=3447003, Yellow=16776960

Tips

  • Webhooks are easiest for simple notifications
  • Bot API requires creating an app at https://discord.com/developers/applications
  • Embed color is a decimal integer (not hex)
  • Max message length: 2000 characters
  • Rate limit: ~5 requests/second per channel

Triggers

discord, send discord message, discord webhook, discord notification, notify discord, discord bot

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

Reviews can't be read right now.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.