Saves Discord chat logs to a file
Find a file
Boden d66b9dab63 feat(validation): comprehensive recurring scraper validation suite and documentation
IMPLEMENTATION UNITS (U1-U6):

U1: Append-only merge test coverage
- Enhanced run-discord-scrape-smoke.sh with additional test scenarios
- Created append-partial-write.json and append-concurrent-conflict.json fixtures
- Added assertions for message sorting, deduplication, and idempotency
- All 10 merge scenarios validated

U2: Error handling validation
- Created error-path-smoke.sh with 6 error scenario tests
- Added test configs for invalid paths, missing files, bad JSON
- Verified fail-closed behavior on all error paths
- No silent data loss on any failure

U3: Cron idempotency and lifecycle
- Created cron-idempotency-smoke.sh with full lifecycle testing
- Created fixture crontab with unrelated entries (preservation test)
- Verified idempotent install, update, and remove operations
- Confirmed dry-run and entry preservation

U4: Preflight and end-to-end setup
- Created end-to-end-preflight-smoke.sh with 10 validation tests
- Verified preflight is read-only and gates cron installation
- Confirmed host-retry auth flow (commit 090884f)
- Added preflight validation section to Scheduling-Linux.md

U5: Documentation completion
- Updated Readme.md with recurring-scraper link
- Created Recurring-Scrape-Setup.md (6300+ chars comprehensive guide)
- Created Recurring-Scrape-Troubleshooting.md (9200+ chars with 30+ scenarios)
- Enhanced .docs/Scheduling-Linux.md with preflight section
- All documented behavior matches implementation

U6: Production-readiness checklist
- Created docs/recurring-scrape-production-checklist.md
- Compiled all validation results (33+ scenarios across U1-U5)
- Documented test execution commands for re-validation
- Provided deployment notes and monitoring guidance
- Clear sign-off criteria established

ARTIFACTS:
- 4 new smoke test scripts (1000+ lines total)
- 4 new fixtures and test configs
- 3 new documentation files (15500+ chars)
- 2 updated documentation files
- 1 validation checklist tracking document
- All tests passing

SAFETY GUARANTEES VERIFIED:
 No silent data loss on any error path
 Fail-closed behavior throughout
 Archive updates are append-only and idempotent
 Cron installation is idempotent
 Unrelated cron entries preserved
 Preflight is read-only
 Token validated before operations
 Path traversal prevented

STATUS: Production Ready
All 6 implementation units complete and validated.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-05-27 12:57:32 -05:00
.assets Update screenshot 2023-02-16 23:16:04 +02:00
.compound-engineering feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
.docs feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
.github feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
config Add recurring CLI scrape automation 2026-05-24 17:04:07 -05:00
DiscordChatExporter.Cli Remove BOM 2026-04-19 23:13:12 +03:00
DiscordChatExporter.Cli.Tests Remove BOM 2026-04-19 23:13:12 +03:00
DiscordChatExporter.Core Add recurring CLI scrape automation 2026-05-24 17:04:07 -05:00
DiscordChatExporter.Gui Refactor fetching Avalonia TopLevel 2026-05-02 11:30:14 +03:00
docs feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
scripts feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
.gitignore feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
Directory.Build.props Remove lang version from build props 2026-05-03 16:01:32 +03:00
Directory.Packages.props Update for Avalonia 12 2026-05-01 16:30:11 +03:00
DiscordChatExporter.Cli.dockerfile Migrate to Centralized NuGet Package Management (CPM) (#1489) 2026-02-26 21:29:46 +02:00
DiscordChatExporter.slnx Standardize repo structure 2026-04-19 16:24:23 +03:00
docker-compose.yml fix(review): apply autofix feedback 2026-05-24 20:30:37 -05:00
docker-entrypoint.sh Fix pathing in docker entrypoint 2024-01-31 21:32:40 +02:00
Dockerfile Add recurring CLI scrape automation 2026-05-24 17:04:07 -05:00
favicon.icns Update favicon 2026-03-31 23:47:26 +03:00
favicon.ico Update favicon 2026-03-31 23:47:26 +03:00
favicon.png Update favicon 2026-03-31 23:47:26 +03:00
global.json Update to .NET 10 2025-11-11 19:46:22 +02:00
License.txt Update license year 2025-12-06 19:20:21 +02:00
NuGet.config Update NuGet.config 2022-04-22 17:03:03 +03:00
Readme.md feat(validation): comprehensive recurring scraper validation suite and documentation 2026-05-27 12:57:32 -05:00
scrape.env.example fix(auth): add host retry flow for discord scrape 2026-05-24 21:07:55 -05:00
STRATEGY.md fix(review): apply autofix feedback 2026-05-24 20:30:37 -05:00

DiscordChatExporter

Status Made in Ukraine Build Coverage Release Downloads Pulls Discord Fuck Russia

Development of this project is entirely funded by the community. Consider donating to support!

Icon

DiscordChatExporter is an application that can be used to export message history from any Discord channel to a file. It works with direct messages, group messages, and server channels, and supports Discord's dialect of markdown as well as most other rich media features.

Warning

While DiscordChatExporter allows it, automating user accounts is against Discord TOS and may result in you getting banned. If possible, use a bot to export chat logs from accessible channels.

Terms of use[?]

By using this project or its source code, for any purpose and in any shape or form, you grant your implicit agreement to all the following statements:

  • You condemn Russia and its military aggression against Ukraine
  • You recognize that Russia is an occupant that unlawfully invaded a sovereign state
  • You support Ukraine's territorial integrity, including its claims over temporarily occupied territories of Crimea and Donbas
  • You reject false narratives perpetuated by Russian state propaganda

To learn more about the war and how you can help, click here. Glory to Ukraine! 🇺🇦

Download

  • Graphical user interface (desktop app):
    • 🟢 Stable release: look for DiscordChatExporter.*.zip
    • 🟠 CI build: look for DiscordChatExporter.*.zip
    • 📦 Scoop: scoop install extras/discordchatexporter (community-maintained)
    • 📦 WinGet: winget install Tyrrrz.DiscordChatExporter.GUI (community-maintained)
    • 📦 AUR: yay -S discord-chat-exporter-gui (community-maintained)
    • 📦 Nix: nix-shell -p discordchatexporter-desktop (community-maintained)
  • Command-line interface (terminal app):
    • 🟢 Stable release: look for DiscordChatExporter.Cli.*.zip
    • 🟠 CI build: look for DiscordChatExporter.Cli.*.zip
    • 🐋 Docker: docker pull tyrrrz/discordchatexporter
    • 📦 WinGet: winget install Tyrrrz.DiscordChatExporter.CLI (community-maintained)
    • 📦 AUR: yay -S discord-chat-exporter-cli (community-maintained)
    • 📦 Nix: nix-shell -p discordchatexporter-cli (community-maintained)

Important

To launch the GUI version of the app on MacOS, you may need to first remove the downloaded file from quarantine. You can do that by running the following command in the terminal: xattr -rd com.apple.quarantine DiscordChatExporter.app.

Note

Community-maintained packages are published independently from this repository and may not always be up to date with the latest release.

Note

If you're unsure which build is right for your system, consult with this page to determine your OS and CPU architecture.

Features

  • Cross-platform graphical and command-line interfaces
  • Authentication via either a user or a bot token
  • Multiple output formats: HTML (dark/light), TXT, CSV, JSON
  • Support for markdown, attachments, embeds, emoji, and other rich media features
  • File partitioning, date ranges, message filtering, and other export options
  • Self-contained exports that can be viewed offline

Screenshots

channel list rendered output

See also