Typescript-DiscordBot-Template provides a solid starting point for creating Discord bots with:
- Clean, modular, and maintainable architecture
- Slash command & event handling system
- Integrated MySQL database support
- Pre-configured tools for development and deployment
- 🧩 Command & Event Templates – Rapidly create and organize bot features.
- 🚀 Deployment Tools – Automatic slash command registration.
- 🗃️ Database Integration – MySQL setup for persistent storage.
- 🔍 Error Logging – Centralized error handling with detailed logs.
- 🛡️ Permission Checks – Role-based access and command restrictions.
- ⏱️ Cooldown System – Prevents command spam.
- 🎯 Scalable Structure – Easy to expand and maintain over time.
- 🧹 Code Quality Tools – ESLint, Prettier, and TypeScript strict mode.
Typescript-DiscordBot-Template/
│
├── src/
│ ├── commands/ # Command files
│ ├── events/ # Event handlers
│ ├── config/ # Configurations (.env loading, constants)
│ ├── handlers/ # Handlers interacting with the bot (Command & Event Handler, Deploy Commands, GuildCommand Manager)
│ ├── services/ # Services Modules (Database MySQL Module)
│ ├── tools/ # Tools functions (Cooldown, Permission Handler, Error Handler)
│ ├── types/ # Interfaces for Commands & Events
│ └── index.ts # Bot entry point
│
├── .env.example # Environment variables template
├── package.json
├── tsconfig.json
└── README.md
# Clone the repository
git clone https://github.com/jmiccoDev/Typescript-DiscordBot-Template
# Move into the project directory
cd Typescript-DiscordBot-Template
# Install dependencies
npm install# Development mode
npm run dev
# Build for production
npm run build
# Start production bot
npm startThis project is licensed under the MIT License.