Case 05 / 17 · Moderation platform for Discord · 2026

Veylix

A moderation platform for Discord: one bot and one web panel for every server, in Russian and English. Cases with terms and a warn ladder, appeals from DMs and on the website, automod with a phishing filter and captcha, shared bans across servers, tickets and reports. For the platform team — an HQ and an admin panel: applications, server curators, a support server with its own bot, forms, a server directory and a status page.

https://veylix.top

  • Development time: 35 days
  • Commands: 50
  • Lines of code: 44,000+
  • Panel and /admin sections: 21

Challenge

Moderation lived in scattered commands and spreadsheets: who punished whom and why was impossible to find, temporary punishments were lifted by hand, appeals got lost in DMs. The bot was tied to a single server: adding another one meant deploying a separate copy, and owners had neither a panel nor a line to the team. One tool was needed — for the moderators of any server, for their owners and for the team that runs the platform itself.

Solution

The bot on discord.js 14 and the panel on React 18 + Vite (Radix UI, TanStack Query, Tailwind) run in one Node.js process: the Express API and WebSocket see the same Discord client and the same database. Data lives in PostgreSQL with versioned migrations, and every table carries a guild_id, so servers are isolated. An owner adds the bot and sets it up with a wizard, while the platform team works in /admin with a permission matrix mapped to roles on the HQ server: applications, curators, the server network, forms. Permissions and limits are checked in one shared function — for slash commands, prefix commands and the panel. Every text of the bot, panel and website goes through i18next (RU/EN), the landing and public server pages are React 19 + TypeScript, a second bot runs the support server, and the database is backed up to S3 every night.

Highlights

Multi-server + HQ + /admin · discord.js 14 + Express + PostgreSQL · 50 commands, RU and EN · Real-time panel

What was built

  • One bot for many servers: the panel lives at /g/<server id>, a start page lists every server, data is isolated
  • A setup wizard with a «Do it for me» button: the bot finds or creates moderator roles, log channels and mute roles with channel restrictions
  • Warn, mute, voice mute, kick, ban and channel lockout — every punishment becomes a case with a number, author, reason and term
  • A warn ladder like “3 warns → 1-hour mute, 5 → 1-day ban”; temporary punishments and temporary roles lift themselves
  • Fine-grained moderator roles: levels, hourly and daily limits, hierarchy, bans and kicks that need a senior's approval
  • Appeals from DMs and on the website — even after a ban; an approved appeal lifts the punishment immediately; case review by another moderator
  • Evidence for a case: a message link (the bot keeps the text and attachments as WebP) or a screenshot via Ctrl + V
  • Automod: banned words, invites, caps, spam, phishing (~22k domains plus Discord and Steam lookalikes), mass mentions, anti-raid, join screening, captcha, per-channel rules
  • Network shared bans: a server sees that a newcomer is banned on other Veylix servers — with reasons, without server names, and with «Ban» and «Watch» buttons
  • Member flags («under watch», «former offender») with a mod-log alert when they join
  • Role panels with buttons or a menu: take-and-drop, only one, take only, roles for a limited time
  • Tickets with categories, priorities and a transcript; in the panel the thread reads like a chat
  • Prefix commands through a shared adapter: both keyboard layouts, Russian aliases, “7d” durations
  • Voice stats, moderator reports with quotas, a weekly summary in Discord
  • A public server page veylix.top/s/<address> and a server directory: covers, tags, languages, rules, moderation team, stats
  • Russian and English: a bot language per server, slash commands with Discord localization, the panel and site follow the browser language
  • Approval mode and applications from the landing page or the panel; in /admin — an assignee, notes, filters and a message to the applicant
  • Server curators: server health, owner requests with attachments and reply templates, reminders and escalation
  • Admin panel /admin: 8 platform roles with a permission matrix, staff, blacklist, bilingual announcements, broadcasts, stats and an audit log
  • Staff can open any server's panel as its owner or read-only: with a reason, for an hour, with every action logged
  • A support server with its own bot: one-click layout, tickets with a diagnosis of the owner's server, answer suggestions in help forums, roles for helping, auto-posted announcements and status
  • Bilingual platform forms: team hiring, owner surveys; an author card, a role and a DM on decision, a summary and CSV
  • A status page status.veylix.top: 90-day uptime and incidents the bot opens by itself
  • Nightly database backups to S3 storage (SigV4 signing without an SDK) with day-based retention
  • Telegram notifications: subscriptions, quiet hours, a digest instead of one-by-one messages
  • The panel updates in real time over WebSocket; the Discord audit log shows which moderator acted through the panel

Stages

  1. Audit and design (2 days) — Teardown of the old bot, the “case” model and its lifecycle, role-based access, the table schema
  2. Bot core and punishments (4 days) — Slash commands, cases, terms and auto-lifting, warn escalation, DMs and logs, role hierarchy checks
  3. Automod, tickets and appeals (3 days) — Automod and anti-raid modules, tickets with transcripts, appeals from DMs, case review, evidence capture
  4. Web panel (4 days) — Discord login, an Express API per section, the React interface, WebSocket updates, an action panel with a DM preview
  5. PostgreSQL and deployment (2 days) — A schema of plain tables with versioned migrations, voice stats and reports, pm2 + nginx + HTTPS
  6. Multi-server and HQ (6 days) — Server context in every route and task, platform roles, approval mode, /admin, owner impersonation with an audit trail
  7. Landing page and applications (2 days) — A React 19 + TypeScript site, application and appeal pages with Discord login, a public API
  8. Prefixes, profile and Telegram (3 days) — A shared prefix-command adapter, Russian layout and aliases, a profile, a Telegram bot with subscriptions
  9. Moderation+ (3 days) — Warn ladder, phishing filter, mass mentions, per-channel rules, captcha, appeals on the website
  10. Curators and onboarding (1 day) — Server curators and owner requests, a setup wizard, member flags, the panel start page
  11. English version and a live site (1 day) — i18next for the bot, panel and landing page, slash-command localization, live numbers, testimonials, changelog, legal pages
  12. Support server (2 days) — A second bot: server layout, tickets with diagnostics, an answer base for forums, contribution roles, auto-posting
  13. Network and reliability (2 days) — Shared bans, the server directory and pages, forms, a status page, S3 backups, role panels and temporary roles

Next project: Digimart