Skip to content

v1.0.0-beta: Discord Bot

Pre-release
Pre-release

Choose a tag to compare

@agntperfect agntperfect released this 22 Jul 11:57

Features

  • Discord Bot Core: Initializes and manages the Discord bot's connection, handling events like ready, guild member additions/removals, and various interactions (commands, buttons, modals).
  • Slash Command Management: Dynamically loads and registers slash commands, making the bot interactive and extensible.
  • Scheduled Tasks: Implements automated, scheduled operations such as:
  • Notice Scraping: Periodically scrapes a website for the latest notices and announces them to a designated Discord channel.
  • Holiday Announcements: Integrates with Google Calendar to fetch and announce holidays.
  • User Management & Moderation:
    • Welcome/Farewell Messages: Sends customizable welcome messages to new members and farewell messages when members leave.
    • Suggestion System: Allows users to submit suggestions, which are stored in a database and can be managed (approved, denied, deleted) by administrators.
  • Verification Workflow Integration: Works in conjunction with other modules (like verify.js) to facilitate user verification, including email sending and database record keeping.
  • Database Integration: Connects to an SQLite database to persist data for features like suggestions, verified users, and birthdays.
  • Email Service Integration: Utilizes an external email service to send verification OTPs and potentially other notifications.
  • PDF Processing: Includes functionality to process PDF files, likely for extracting information from notices.
  • Robust Error Handling: Incorporates mechanisms to log and handle unhandled promise rejections and various Discord client errors, contributing to the bot's overall stability.
  • Central Orchestrator: bot.js serves as the main entry point for the Discord bot application. It initializes all necessary components, sets up event listeners, and orchestrates interactions between various modules and external services.
  • Modular Design: It leverages a modular structure, importing functionalities from dedicated service files (e.g., emailService.js, scraper.js) and command files, promoting code organization and reusability.
  • Configuration Management: Relies heavily on dotenv for environment variable management, ensuring sensitive information (like bot tokens, API keys, and role IDs) is kept out of the codebase and easily configurable.
  • External Service Integrations: Demonstrates integration with several external services, including Discord API, a custom email service, a web scraper, and Google Calendar, showcasing its capability to interact with various platforms.
  • Persistent Storage: Utilizes an SQLite database (database.js) for persistent data storage, allowing the bot to maintain state across restarts for features like user verification, suggestions, and birthdays.
  • Comprehensive Logging: Features extensive console logging for various operational stages and error conditions, which is crucial for monitoring the bot's health and diagnosing issues in a production environment.

What's Changed

  • feat(docker): Add Dockerfile with graphicsmagick for PDF processing by @agntperfect in #20

New Contributors

Full Changelog: https://github.com/FSU-Pulchowk/discord-bot/commits/v1.0.0