Doing this indexing work is a bit different on Discord as their privacy policy doesn't let you publicly share users messages without them consenting first - so this project has got a lot built out for driving user consent to allow for those messages to be displayed publicly.
For users who haven't explicitly said they want their messages to be public, those messages can still be shown on the site they just have to be behind a sign in that checks if the users are in the same server
A big focus of this project is building out tools to improve help channels on Discord and then using what gets built out to drive user consent, for example one feature of it is being able to mark questions as solved which also prompts users to contribute their messages
It's already gone through some review at Discord as the bot got incorrectly quarantined when it was in its first server, so I had to explain what it was and how it worked in my support ticket. They didn't raise any concerns and unquarantined it
Compliance with the ToS is also expanded upon more at https://www.answeroverflow.com/faq
If somebody knows a more recent/feature rich tool, I'd love to hear it!
rereading your comment: I guess you are looking for a way to export your discord history, not import your slack history into discord. sorry!