You are an expert Discord bot developer. Build a complete, working Discord bot in Node.js (discord.js v14) for a Minecraft server called VentozSMP.
SERVER INFO (use exactly these values, configurable via a config.js/.env file):
- Java/Bedrock IP: play.ventozsmp.online
- Version: 1.21.11 (also compatible with 1.26.1.2)
- Bedrock port: 8016
- Java port: 25565 (default, confirm/adjust if different)
CORE FEATURE — AUTO IP RESPONDER:
- Listen to every message (non-command).
- Trigger ONLY when a message is exactly "ip" or "ip?" (case-insensitive, trimmed), NOT when "ip" appears inside other words/sentences (e.g. "skip", "what is my ip", "trip" must NOT trigger).
- Use word-boundary/exact-match logic, not .includes().
- On trigger, reply with an embed containing:
- Server name/banner title "VentozSMP" - Java IP: play.ventozsmp.online - Bedrock IP: play.ventozsmp.online | Port: 8016 - Version: 1.21.11 (works on 1.26.1.2) - A footer and thumbnail/server icon if available
- Ignore bots, ignore messages inside threads if needed, rate-limit so it doesn't spam if multiple people type "ip" quickly.
SLASH COMMANDS (every command must be a working "/" slash command, registered via Discord's application command API):
General/Info:
- /ip — same embed as auto-responder
- /status — live server status: online/offline, current players, max players, current version, MOTD (use a Minecraft server status API like mcsrvstat.us or minecraft-server-util npm package for both Java and Bedrock)
- /players — list currently online players
- /vote — voting links (placeholder)
- /store — store link (placeholder)
- /rules — server rules embed
- /discord — invite/info
- /uptime — bot + server uptime
- /ping — bot latency
Stats:
- /stats [user] — Minecraft playtime/stats if linked, else Discord stats (messages, join date)
- /leaderboard — top players by playtime/kills (placeholder data source, structure it so it can connect to a database later)
- /serverinfo — Discord server member count, boosts, channels count
- /botinfo — bot version, uptime, servers count, library version
Moderation (full suite, permission-gated):
- /kick [user] [reason]
- /ban [user] [reason] [delete_message_days]
- /unban [user_id]
- /timeout [user] [duration] [reason]
- /untimeout [user]
- /warn [user] [reason] — store warnings (in-memory or JSON/SQLite)
- /warnings [user] — view warning history
- /clearwarnings [user]
- /purge [amount] [user(optional)] — bulk delete messages
- /lock [channel] — lock a channel
- /unlock [channel]
- /slowmode [seconds] [channel]
- /mute [user] [reason] (role-based fallback if no timeout perms)
- /unmute [user]
- /nickname [user] [new_nick]
- /role add/remove [user] [role]
- /modlogs [user] — full moderation history
- All moderation actions must:
- Check the executor's permissions before running - Log the action to a designated mod-log channel with embed (action, moderator, target, reason, timestamp) - DM the target user when reasonably possible (kick/ban/warn/timeout) with reason
Utility/Fun (add as many as reasonable):
- /poll [question] [options]
- /announce [channel] [message] (admin only)
- /embed [title] [description] [color] (admin only, for custom announcements)
- /avatar [user]
- /userinfo [user]
- /coinflip
- /8ball [question]
- /remindme [time] [message]
TECHNICAL REQUIREMENTS:
- Use discord.js v14 with SlashCommandBuilder for every command.
- Organize code with a command handler that loads each command from a /commands folder (separate file per command).
- Use an events folder for ready, messageCreate (for the IP auto-responder), interactionCreate, guildMemberAdd, etc.
- Store config (token, client ID, guild ID, server IP/port/version, mod-log channel ID, etc.) in a config.js or .env — never hardcode the bot token in code shown.
- Use minecraft-server-util or mcsrvstat.us API for real-time /status and /players.
- Use a lightweight persistence layer (JSON file or SQLite via better-sqlite3) for warnings/mod logs/stats so data survives restarts.
- Include error handling (try/catch) around all command executions and API calls.
- Include a deploy-commands.js script to register slash commands.
- Include a package.json with all dependencies and a README explaining setup (token, IDs, npm install, node deploy-commands.js, node index.js).
- Code must be complete and runnable, not pseudocode — write out every file in full.
Deliver the full file structure and all code, file by file.
No files in this session