diff --git a/src/listeners/global.h b/src/listeners/global.h new file mode 100644 index 0000000..c7e7482 --- /dev/null +++ b/src/listeners/global.h @@ -0,0 +1,29 @@ +#ifndef BOT_GLOBAL_H +#define BOT_GLOBAL_H + +#include <dpp/dpp.h> +#include <mariadb/conncpp.hpp> + +class global { + +public: + /** + * @brief Sends a message to the webhook + * @param url The webhook url + * @param bot The bot + * @param event The event + */ + static void send(const std::string &url, dpp::cluster &bot, const dpp::message_create_t &event); + + /** + * @brief Executes the global listener + * @param con The database connection + * @param bot The bot + * @param event The event + */ + static void execute(sql::Connection &con, dpp::cluster &bot, const dpp::message_create_t &event); + +}; + + +#endif //BOT_GLOBAL_H