Discord Bot — A billing system for game server hosting
A fully functional Discord bot for automating billing and managing game servers based on Pterodactyl Panel.
Tech stack: #Node.js 22, #discord.js v14, #SQLite (node:sqlite), #Express, #node-cron, #Pterodactyl Application/Client API, #Donatello webhook.
Implemented features:
Personal #client dashboard in DMs with step-by-step navigation via embeds and buttons
Full #billing cycle: registration/linking of Pterodactyl accounts, balance top-ups via Donatello.to, purchase/renewal/cancellation of plans with pro-rated refunds.
#Discounts for subscriptions (3/6/12 months), short-term rentals (1 day / 3 days / week), 24-hour trial period.
#Server auto-deployment upon purchase: dynamic egg configuration via the Pterodactyl API, automatic selection of a free port.
#Auto-renewal of plans, automatic suspension upon expiration (cron every 5 minutes with catch-up upon restart).
#Multi-server on a single subscription (sub-servers), upgrade/downgrade with prorated billing.
Full-featured #admin panel: CRUD for plans, user management with pagination, server import, balance editing.
Support #ticket system: separate channels, auto-assignment of embed, statuses (open/accepted/closed), log channel.
Trilingual #localization (UA/EN/PL) with real-time switching.
#Role system: automatic assignment of the “customer” role when active servers are present.
Tech stack: #Node.js 22, #discord.js v14, #SQLite (node:sqlite), #Express, #node-cron, #Pterodactyl Application/Client API, #Donatello webhook.
Implemented features:
Personal #client dashboard in DMs with step-by-step navigation via embeds and buttons
Full #billing cycle: registration/linking of Pterodactyl accounts, balance top-ups via Donatello.to, purchase/renewal/cancellation of plans with pro-rated refunds.
#Discounts for subscriptions (3/6/12 months), short-term rentals (1 day / 3 days / week), 24-hour trial period.
#Server auto-deployment upon purchase: dynamic egg configuration via the Pterodactyl API, automatic selection of a free port.
#Auto-renewal of plans, automatic suspension upon expiration (cron every 5 minutes with catch-up upon restart).
#Multi-server on a single subscription (sub-servers), upgrade/downgrade with prorated billing.
Full-featured #admin panel: CRUD for plans, user management with pagination, server import, balance editing.
Support #ticket system: separate channels, auto-assignment of embed, statuses (open/accepted/closed), log channel.
Trilingual #localization (UA/EN/PL) with real-time switching.
#Role system: automatic assignment of the “customer” role when active servers are present.