This script allow for user specific message deletion from an entire server or a single channel using the browser console. This script uses discord search API and it will only delete messages of a chosen user.
Go to user settings > appearance in discord and enable Developer mode.
Open discord and right click on the server icon and click copy id. Replace the server id in the script with your server id. Do the same process for the author id by right clicking the avatar image.
Press F12 in Chrome or Firefox to open the console. Paste the modified script in the console and press enter.
The more messages the longer it takes. You can check if the messages have been deleted by using the search.
I think there are some channels that this script won't work with. I think they may be NSFW channels but I haven't tested enough.
Use this script at your own risk
This script was based on the following scripts https://gist.github.com/niahoo/c99284a8908cd33d59b4aff802179e9b#gistcomment-2397287 https://gist.github.com/IMcPwn/0c838a6248772c6fea1339ddad503cce
Hey folks, I know its a dead thread but i figured it liven it up a little to show off something i have been working on for a bit. I wrote this script because I hate my logs getting spammed with errors and having a UN-optimized deletion script as the first result on google. This script has a test mode for seeing if it works at all with a limited number of deletions. A list for the channels you want removed from and a automatic server wide channel detection system for server wide message wipes. I shouldhave also thrown in author deletions too but i dident haha!
Also, I added a method of caching, this will allow you to resume deletions even after you lose power or close the website, its a nifty feature.
Still a work in progress and if I improve it further i will post it here.