Discord Export Wizard Project [2024]

Simplifying Discord Chat Exports for Non-Technical Users


1. Project Overview

Existing Discord chat exporters either produce incomplete results (missing images/media) or require command-line expertise. I developed an accessible solution for non-technical users to reliably archive sensitive conversations.

The resulting tool has the following workflow:

  1. Web UI guides users through export process
  2. Kubernetes Backend orchestrates Dockerized processing jobs, leveraging existing discord-chat-exporter and singlefile tools
  3. Uploads self-contained HTML file with full media to NextCloud
  4. Automatic cleanup of sensitive credentials

Technologies: Kubernetes, Rust, Python, Javascript, ArgoCD

Source: snowpoke93/discord-export-wizard

2. Technical Implementation

System Architecture

Simplified workflow: User → Web UI → Controller → Processing Jobs → NextCloud

Core Components:

  1. Rust Controller (API)
    • Manages Kubernetes jobs/secrets
    • Implements rate limiting
  2. Python Web UI
    • Simple form for channel ID/token input
    • Real-time job status display
    • Download link generation
  3. Processing Pipeline
    • Kubernetes Jobs with PVCs for intermediate storage
    • Chained containers: discord-chat-exporter → singlefile-cli
    • Automatic secret rotation per job

Key Technologies

  • Kubernetes: Job orchestration, PVCs for data sharing between containers
  • Rust: High-performance controller API (Poem framework)
  • HTML/JavaScript/Python: Browser-based frontend
  • Gitlab CI/ArgoCD: GitOps deployment to development/production clusters

3. Security & Operations

Critical Design Choices:

  1. Ephemeral Secrets: Discord tokens stored in short-lived Kubernetes Secrets
  2. Isolated Processing: Each export runs in dedicated namespace
  3. Mandatory Cleanup: PVCs/Secrets deleted on job completion
  4. Private Tool: Web UI only accessible with password

4. Impact & Future Directions

Achievements:

  • Enabled non-technical team members to archive critical channels
  • Reduced export process from error-prone manual steps to single click
  • Error rate in chat exports decreased from ~70% to ~10%.