How eniiju/movetool works
Project type and purpose
• This is a backend service: a Discord bot built in Node.js (TypeScript) using discord.js.
• Purpose: provide slash‑commands and context‑menu commands to move voice‑channel members on Discord and optionally log those actions into a MongoDB database.
File structure
• Top‑level config and orchestration files:
• Dockerfile, docker-compose.yaml, mongo-init.sh – define containerized deployment with a MongoDB service
• .github/workflows/deploy.yml – CI/CD pipeline for building and deploying the containers
• src/commands – individual command handlers organized under chatInput and contextMenu
• src/events – event listeners for Discord gateway events (ready, interactionCreate, guildDelete, shardError)
• src/lib – shared utilities (message formatting, moving logic, general helpers)
• src/modules – core modules: Database.ts (Mongo connection), Logger.ts (logging service)
• src/registerCommands.ts – registers slash and context‑menu commands with the Discord API
• src/index.ts – application entry point that initializes config, modules, registers commands, and starts the Discord client
README for additional insights
• Lists all slash commands (assemble, move, split, enable logging, logs, follow) and context‑menu commands
• Describes permissions required and basic usage
Elements
• Clear labels: e.g., “Discord Gateway”, “Bot Service (Node.js)”, “MongoDB”
• From Discord to Bot (incoming events)
• From Bot to MongoDB (read/write logs)
• From Bot to Discord (responses)
• From GitHub Actions to Docker/Server (deployment)
• Another for the database