Browse json files exported by Tyrrrz/DiscordChatExporter in familiar discord like user interface https://dcef.slada.sk
Find a file
2023-08-02 01:26:08 +02:00
.github wipe database on program upgrade 2023-06-01 18:13:47 +02:00
backend preprocess filefinder - handle PermissionError 2023-07-31 23:40:22 +02:00
docs documentation revamp 2023-08-02 01:26:08 +02:00
frontend ts - update Role type 2023-07-31 23:42:43 +02:00
release wipe database on program upgrade 2023-06-01 18:13:47 +02:00
.dockerignore add docker support for linux users 2022-11-09 04:03:06 +01:00
.gitignore wipe database on program upgrade 2023-06-01 18:13:47 +02:00
BUILD_RELEASE.bat include dlls from Visual C++ Redistributable 2023-02-15 21:24:48 +01:00
DEV.bat switch to windows terminal for dev setup 2023-02-07 17:24:41 +01:00
Dockerfile github action to build and publish docker image 2023-04-15 04:04:20 +02:00
LICENSE add license file 2023-03-25 01:44:00 +01:00
README.md documentation revamp 2023-08-02 01:26:08 +02:00
REDOWNLOAD.example.bat better folder structure v2 2022-11-24 22:04:17 +01:00

DiscordChatExporter-frontend (DCEF)

Browse your Discord chat exports in a familiar discord like user interface. Try a demo in your browser :).

Want to chat? Join Tyrrrz's discord server. I usually hang out in #dce-frontend channel

Downloads

Windows (stable binary release)

Linux (docker image)

Quick start (Windows)

  1. Download the latest release from releases page
  2. Extract the archive
  3. Move your DiscordChatExporter JSON exports to /exports/ folder (supported exports).
  4. Run dcef.exe

Quick start (Linux)

Docker version is the best way to host the viewer on a server for others to use.

  1. pull the image from docker hub
docker pull slada/dcef:main
  1. Navigate to a folder with your exports
cd /path/to/your/exports
  1. Run the container
docker run --restart=always --volume "$(pwd):/dcef/exports" --volume dcef_cache:/dcef/cache --rm --name dcef -p 21011:21011 -it slada/dcef:main
  1. Open http://127.0.0.1:21011/ in your browser

Note: arm based systems like Raspberry Pi or Apple M1 are not officially supported. Pull requests are welcome :)

Other ways to run DCEF

Windows beta builds

If you want to try out the latest features, you can use beta builds. They are automatically built from the latest commit on main branch. You need to be logged in to Github account to download them.

Build docker image from source code

You need docker and git installed. Then run:

git clone https://github.com/slatinsky/DiscordChatExporter-frontend
cd DiscordChatExporter-frontend
docker build -t dcef .

Then use the same instructions as for the Linux docker version, but replace in commands slada/dcef:main with dcef.

Upgrade guide

Upgrade windows binary release

Want to upgrade from previous version? Follow these steps:

  1. Download the latest release from releases page.
  2. Delete everything (except exports folder) in your discordchatexporter-frontend folder.
  3. Move everything (except exports folder) from the new release to your discordchatexporter-frontend folder.
Upgrade docker image
cd path/to/your/exports/
docker rm dcef --force
docker image rm slada/dcef:main
docker pull slada/dcef:main
docker run --restart=always --volume "$(pwd):/dcef/exports" --volume dcef_cache:/dcef/cache --rm --name dcef -p 21011:21011 -it slada/dcef:main

Uninstall

Windows (binary release)

DCEF does not create any files outside of its folder, so you can just delete the folder to uninstall it.

Move your exports folder somewhere else if you want to keep your exports.

Linux (docker)
  1. kill and delete the container
docker rm dcef --force
  1. remove the volume
docker volume rm dcef_cache
  1. remove the image
docker image rm slada/dcef:main

How to export data from Discord to view it in DCEF?

JSON exports are created using DiscordChatExporter.

Partial export using GUI version of DiscordChatExporter

Make sure that export format is set to JSON and Format markdown is disabled. Optionally, you should also enable Download assets+Reuse assets option to download images, videos and other types of assets.

NOTE: You can't export threads and forums using GUI version of DCE. You need to use CLI version for that.

Full guild export using CLI version of DiscordChatExporter
  • JSON export format (--format Json) is required
  • Downloading assets (--media --reuse-media) is highly recommended, but not required
  • Skipping markdown prerendering (--markdown false) is highly recommended, but not required

Export all accessible channels in a guild (without threads and forum posts):

DiscordChatExporter.Cli.exe exportguild --token DISCORD_TOKEN -g GUILD_ID --media --reuse-media --markdown false --format Json --output OUTPUT_FOLDER_PATH

Export threads/forum posts (you can pass multiple thread/forum post ids):

DiscordChatExporter.Cli export --token DISCORD_TOKEN  --media --reuse-media --markdown false --output OUTPUT_FOLDER_PATH --format Json --channel THREAD_ID_OR_FORUM_POST_ID_1 THREAD_ID_OR_FORUM_POST_ID_2 THREAD_ID_OR_FORUM_POST_ID_3 THREAD_ID_OR_FORUM_POST_ID_4

Don't want to manually right click all threads/forums post and copy their ids? These helper scripts can help you:

Helper script to export archived threads in a channel

Helper script to export forum posts in a channel

Export private messages using CLI version of DiscordChatExporter

Export all dms (sadly, exporting dms can't be done without selfboting):

DiscordChatExporter.Cli.exe exportdm --token DISCORD_TOKEN --media --reuse-media --markdown false --format Json --output OUTPUT_FOLDER_PATH

FAQ

Some assets are not showing on Windows

Files in /exports/ folder may exceed Windows path length limit of 260 characters. If you have any issues with loading your assets you can choose one of the following solutions:

  • move DCEF to a folder with shorter path
  • or run registry_tweaks/change_260_character_path_limit_to_32767.reg to increase the limit to 32767 characters (requires admin privileges) and restart your computer. To revert this change, run registry_tweaks/restore_260_character_path_limit.reg and restart your computer.
DCEF hangs and prints `Slow SessionWorkflow loop` to the console

Slow SessionWorkflow loop messages are completely normal - if you see them, you know that data is pushed to mongodb database and the process is not stuck. Just be patient and wait for the process to finish. If you have a lot of exports, it may take a while.

DCEF is not just an simple viewer. This process enriches your exports with additional data and stores them in a database for search and other features to work.

DCEF won't run on M1 mac

This pull request may help you

For developers

Architecture choices

Setting up a development environment on Windows

Compile the Windows release from source code

Supporting other exporters

Thanks

And for other technologies used in this project - sveltekit, docker, nodejs, nvm, pyinstaller, nginx, mongodb

License

GNU GENERAL PUBLIC LICENSE. See LICENSE for more details.

This product contains software provided by NGINX and its contributors.

DiscordChatExporter-frontend is not affiliated with Discord. Discord is a registered trademark of Discord Inc.

Contributing

Feel free to open issues and pull requests.

Short guide, how to contribute

  • Fork the repository
  • Create a new branch
  • Implement your changes
  • Commit and push the changes
  • Create a pull request

If you find this project useful, please consider starring it here on GitHub :)