This is built into Android. A program like Discord has very granular controls over each type (DM, server event, stage event, etc) of notification as well as controls for each source (You can set a specific users DMs to be priority messages, silenced, show/hide from lock screen, etc).
A program like Uber Eats has a bit less benefit to allowing such controls over what they send you. While they do still break down messages by type, their descriptions are a bit cryptic and after getting an unsolicited notification from it, I ended up disabling all of them.