I can't find the page now but iirc someone had attempted the same idea and got some serious backlash from the communities/servers scanned and eventually shut the project down. I agree, though, that discord really needs to be searchable; at least project pages and the like.
Project pages and the like don't belong on Discord.
An appropriate indexer would obviously distinguish between those and actual semi-private chats (where I assume backlash came from). And would probably get shut down after a while anyway either by being banned for ToS violation or the maintainer quitting because maintaining such project gets grating enough anyway at some point.
Relevant conversations moving off Discord is what's really needed and where I think effort is better spent though.