Discrawl

v0.1.0

Mirror Discord guild data into a local SQLite archive for search, inspection, and agent queries. Bot-token only, no user-token hacks. Data stays local.

0· 34· 1 versions· 0 current· 0 all-time· Updated 5h ago· MIT-0
byChase Webb@chasewebb

Discrawl

Local-first Discord crawler. Pulls guild metadata, channels, and message history into ~/.discrawl/discrawl.db (SQLite) so an agent can query history without depending on Discord search.

Requirements

  • Discord bot token (not a user token). Create one at https://discord.com/developers/applications.
  • Bot must be invited to each guild you want to mirror, with permissions to read message history.
  • discrawl binary on PATH.

Setup

export DISCORD_BOT_TOKEN="your-bot-token"
discrawl doctor       # verify token + permissions
discrawl init         # create local config + database
discrawl sync --full  # initial sync of all accessible guilds

If you already use OpenClaw, discrawl can reuse ~/.openclaw/openclaw.json for shared config.

State

  • Config: ~/.discrawl/config.toml
  • Database: ~/.discrawl/discrawl.db

Common Commands

discrawl status                       # last sync, row counts
discrawl sync --incremental           # pull new messages since last run
discrawl guilds list --json
discrawl channels list --guild <id> --json
discrawl messages list --channel <id> --limit 100 --json
discrawl search "keyword" --json
discrawl sql 'SELECT count(*) FROM messages'   # raw SQL

Integration Notes

  • Read-only against Discord; only writes to the local SQLite file.
  • Use --json on every command for agent-parseable output.
  • Schedule incremental syncs via PaperFang cron for continuous mirroring.

Version tags

crawlervk972pdj6bkdtw257zzx65g8qrx85qj6mlatestvk972pdj6bkdtw257zzx65g8qrx85qj6mlocal-firstvk972pdj6bkdtw257zzx65g8qrx85qj6mpaperchasevk972pdj6bkdtw257zzx65g8qrx85qj6m

Runtime requirements

🎮 Clawdis
OSmacOS · Linux
Binsdiscrawl
EnvDISCORD_BOT_TOKEN

Install

Install discrawl (brew)
Bins: discrawl
brew install steipete/tap/discrawl