agentleFS
yuhua99yuhua99/skills/discord/SKILL.md

discord

Skill2 starsChanged 30 days agoMITView on GitHub

Read-only Discord access through a local message cache. Use when the user asks what happened in a Discord server or channel, wants a Discord discussion summarized, or wants to find a Discord message, topic, or person's messages.

34 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use taskflow-inbox-triage, voice-call and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • AtomicBot-aiSkill

    taskflow-inbox-triage

    Also in 6 projects that use this

  • seedprodSkill

    voice-call

    Start voice calls via the OpenClaw voice-call plugin.

    Also in 17 projects that use this

  • seedprodSkill

    session-logs

    Search and analyze your own session logs (older/parent conversations) using jq.

    Also in 17 projects that use this

  • hkyutongSkill

    openclaw-release-maintainer

    Maintainer workflow for OpenClaw releases, prereleases, changelog release notes, and publish validation. Use when Codex needs to prepare or verify stable or beta release steps, align version naming, assemble release notes, check release auth requirements, or validate publish-time commands and artifacts.

    Also in 4 projects that use this

  • AtomicBot-aiSkill

    taskflow

    Also in 6 projects that use this

  • +7 more from seedprod

The file

We split this skill into the rules it gives an agent

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

  • 0

    Common

    Most of the 31 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use the bundled script scripts/discord.py, resolved relative to this SKILL.md (not the caller's cwd).

    line 6
  2. Very specific:

    Every command prints one JSON object: {"ok": true, "data": ...} or {"ok": false, "error": {"code", "message"}}.

    line 17

“Common” is measured: kept by at least 6 in 10 of the 31 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

Use the bundled script scripts/discord.py, resolved relative to this SKILL.md (not the caller's cwd). Run it with python3.

Ground rules

  • Read-only. The script syncs and reads; it cannot post, react, or edit.
  • Sync before read. search, recent, and stats read only the local cache. A channel that was never synced does not exist for them; dc * commands hit the Discord API.
  • IDs over names. Pass channel and guild IDs once you have them. Names must match exactly (case-insensitive); a name shared across guilds is rejected as ambiguous.
  • Light traffic. It runs on the user's own Discord user token; heavy automation risks account restrictions. Scope every sync to the channels the task needs.

Output

Every command prints one JSON object: {"ok": true, "data": ...} or {"ok": false, "error": {"code", "message"}}.

Workflow

  1. Check auth: status. Done when ok is true. On not_authenticated / invalid_token, ask the user to set DISCORD_TOKEN in the environment this agent runs in (usually: export it, then restart the agent); the token stays out of the chat.
  2. Locate the channel: dc guilds → dc channels <guild>. Done when you hold the channel ID.
  3. Sync: dc sync <channel_id>. For a first sync, add --hours N matching the period the user cares about. Done when has_more is false; otherwise run the same sync again.
  4. Read:
    • Catch-up or summary → recent -c <channel_id> --hours N -n 200 (oldest first).
    • Topic lookup → search "<keyword>" -c <channel_id>, narrowing with --sender / --hours.
    • Channel never synced and only a lookup is needed → dc search <guild> "<keyword>" (Discord's own search, no sync). Done when every claim in your answer traces to a returned message (sender + timestamp).

Commands

python3 scripts/discord.py status
python3 scripts/discord.py dc guilds
python3 scripts/discord.py dc channels <guild>
python3 scripts/discord.py dc sync <channel_id> [--hours N]
python3 scripts/discord.py dc search <guild> "<keyword>" [-c <channel_id>] [-n N]
python3 scripts/discord.py search "<keyword>" [-c CHANNEL] [-g GUILD] [--sender NAME] [--hours N] [-n N]
python3 scripts/discord.py recent [-c CHANNEL] [-g GUILD] [--hours N] [-n N]
python3 scripts/discord.py stats
  • stats shows which channels are cached and how fresh each one is.
  • dc sync continues from the newest cached message. With --hours, it starts at the cutoff instead and the gap before it is never backfilled.

Errors

error.codeAction
not_authenticated, invalid_tokenAsk the user to set DISCORD_TOKEN
empty_databaseRun step 3 first
channel_resolution_errorNot synced yet, or ambiguous: use the channel ID or add -g
guild_resolution_errorUse the guild ID from dc guilds
forbidden, not_foundThe account cannot see that guild/channel; tell the user
other codesRetry once, then report the message to the user

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.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

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.