Skip to content

A discord bot which filters messages for specified keywords or regular expressions

License

Notifications You must be signed in to change notification settings

muckee/discord-py-message-filter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors Forks Stargazers Issues EPL-2.0 License


Discord Python Message Filter

A discord bot which filters messages for specified keywords or regular expressions.
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License
  7. Contact
  8. Acknowledgments

About The Project

This library was written to act as a simple boilerplate for developing a message filter for Discord. Messages are compared against the strings in expressions.json and are deleted where there are matches.

Each string can be formatted as either plain-text, or as a regular expression - the value of the 'type' property of each expression must equal 'string' or 'regex', respectively, as can be seen in the example.

(back to top)

Built With

  • Python
  • wheel
  • python-dotenv
  • discord-py-interactions

(back to top)

Getting Started

The following instructions will explain how to download, install and run the application locally. Instructions for deploying this application in a production environment are beyond the scope of this application.

Prerequisites

It is necessary to install the following software in order for the application to run properly.

  • python
    apt install python3 pip
  • dependencies
    pip install python-dotenv discord-py-interactions

Create an application with a bot from within the Discord Developer Portal.

The only privileged intent required is the 'Message Content Intent'.

The only permissions required when inviting the bot to a server are the 'manage messages' and 'read messages/view channels' permissions.

Installation

  1. Clone the repo
git clone https://github.com/muckee/discord-py-message-filter.git
  1. Update environment variables
cd discord-py-message-filter
cp .env.sample .env
vi .env

(back to top)

Usage

You can start the bot by running python3 main.py from inside the project's root directory.

(back to top)

See the open issues for a full list of proposed features (and known issues).

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the EPL-2.0 License. See LICENSE.txt for more information.

(back to top)

Contact

Muckee - @muckee_eth - [email protected]

Project Link: https://github.com/muckee/discord-py-message-filter

(back to top)

Donations

If this library has helped you to make a bag, please consider making a donation to one of the following addresses:

  • Solana: 7tKA18pUNF3hHBTMWd1BFfj1iVcggKbcB1TxxJnrhiKW
  • Monero: 857PeoGenpWLGDQNPGYHohRa6EmxocCYWDyDnQvNChbtXBhZQgrr3BW6Vjvpy4EiZrBMqgfdH2bCcRzxKu6yy54TMXRTMQ3
  • Ravencoin: RGN5nDGsU51EriSYA4RAddregrS2LzB5FJ
  • Bitcoin: bc1qkajr4e9lqq9elk6pdafk7x3x8kk9zqlndrxuh8
  • Stellar: GD6KWYMF6T3ZQ7DFC4AEKSMAEZL7FCSDFPTN6VKHBVM4YYOGXF4VM2XY
  • Near: 349d3b53b98040c6ecafa3759beb9f39a025d32bb4db51baab7652af6a0d67bb
  • ETH/BNB/MATIC: 0xE078B9524549585d6eF21542a7927751b2a85E89

About

A discord bot which filters messages for specified keywords or regular expressions

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages