Clear all discord DMs with a discord data request
Go to file
2024-09-16 15:24:53 +02:00
imgs first commit 2024-09-06 16:41:24 +02:00
src ref: replace by default node module 2024-09-16 15:24:53 +02:00
.gitignore chore: Update .gitignore and package.json, add bun build script 2024-09-09 00:39:45 +02:00
.prettierrc feat: add information about the channel (total deleted messages, total messages, pourcent and total channel remaining) 2024-09-07 02:26:14 +02:00
package.json chore: Update .gitignore and package.json, add bun build script 2024-09-09 00:39:45 +02:00
README.md feat: Update readme 2024-09-09 00:54:28 +02:00
tsconfig.json first commit 2024-09-06 16:41:24 +02:00
yarn.lock chore: Update .gitignore and package.json, add bun build script 2024-09-09 00:39:45 +02:00

Discord DM Deletion Script

This script allows you to delete all your direct messages (DMs) on Discord using data retrieved through a data request to Discord. It fetches the IDs of your sent messages and deletes them automatically.

How to Request Your Data from Discord

  1. Log in to your Discord account.
  2. Click on User Settings at the bottom left.
  3. Go to the Privacy & Safety section. User Settings
  4. Scroll down to the Request Data section. Privacy & Safety
  5. Select "Messages" and click on Request Data. Request Data
  6. Discord will send you a download link via email once your data is ready. This may take several days.

Once you receive and download your data, you will find a file containing all the messages you have sent, including their IDs. This file will be used by the script to delete your messages.

Installation

Using executable

  1. Download the executable from the releases page.
  2. Extract the messages file from your Discord data request and place it in the same directory as the executable.
  3. Run the executable with the following command:
.\ClearMessages.exe "UR_TOKEN"

To show messages content

.\ClearMessages.exe "UR_TOKEN" debug

Using nodejs

  • Node.js installed on your machine.
  • Yarn installed to manage dependencies.
    • npm i -g yarn
  1. Clone this repository or download the project files to your machine:
git clone https://github.com/M1000fr/clear-all-discord-dm.git
  1. Navigate to the project directory:
cd clear-all-discord-dm
  1. Install the project dependencies:
yarn install
  1. Extract the messages file from your Discord data request and place it in the project directory. This should be look like this:
.
├── messages
│   ├── c{CHANNEL_ID}
│   │   ├── channel.json
│   │   └── messages.json
│   ├── ...
│   └── index.json
  1. Build
yarn build
  1. Run the script:
node . "UR_TOKEN"

To show messages content

node . "UR_TOKEN" debug