This is a bot I made for the programming books community here on programming.dev to prevent pirating but can be adapted to any community.

It has functionality for both a whitelist and a blacklist and has templates so you can share ban lists between communities. It also detects in both posts and comments

Since it deals with deleting messages it needs mod permissions in communities you want to use it for

Feel free to dm me if you need some help with getting it set up