Ticker Boy is a feature-rich, production-ready Discord bot designed specifically for advanced ticket management in Discord servers. Built with Discord.js v14, it provides a professional support system for communities, gaming servers, and businesses.
- Streamline Support: Users create tickets via interactive buttons/menus, staff claim/resolve them with transcripts.
- Admin Dashboard: Configure everything via
/settings(language, panels, roles, logs, claims). - Scalable: Supports thousands of servers with multi-DB options (JSON, MySQL, MongoDB).
- Customizable: Multi-language (EN/Persian), themes, embeds, and permissions.
Version 1.3.9 Highlights:
- Fixed Ticket Bugs: Improved stability in create/close/claim flows.
- Enhanced Buttons: Better interaction handling, no more "interaction failed" errors.
- Quality Improvements: Optimized DB queries, reduced memory usage, better error logging.
- New Features: Claim system toggle, parent category support (open/close), menu options, mod logs.
- Dashboard: Express-based web interface for stats/settings.
- Transcripts: HTML exports for closed tickets (via
discord-html-transcripts). - Multi-Language: EN-US & Persian with dynamic localization.
- Webhook Logging: Auto-reports joins/leaves/errors to support server.
- Anti-Crash: Full error handling with webhook alerts.
Perfect for support teams needing fast, organized ticket handling without manual channels.
| Feature | Description |
|---|---|
| Interactive Tickets | Button/menu-based creation, claim, close, reopen, rename, add/remove users, delete. |
| Admin Dashboard | /settings with select menus, modals, buttons for full customization. |
| Multi-DB Support | JSON (default), SQLite, MySQL, MongoDB via QuickDB/QuickMongo. |
| Claim System | Staff claim tickets; toggleable, with permissions. |
| Transcripts | Auto-generate HTML transcripts on close/delete, DM to staff. |
| Logging | Mod logs, webhook alerts (joins/leaves, errors, reports). |
| Parent Categories | Auto-move tickets to open/close categories. |
| Multi-Language | English & Persian; per-guild configurable. |
| Permissions | Granular role-based access (admin roles, ManageChannels). |
| Cooldowns | Per-command, per-user (configurable). |
| Status Updates | Auto-updating bot stats embed in support server (servers, users, ping, uptime, CPU/memory). |
| Anti-Crash | Catches unhandled errors, logs to webhook/console. |
| Dashboard | Web UI (Express + EJS) for stats (localhost:3000). |
| Commands | Slash + Prefix support; categories: Admin, Misc, Owner, Ticket. |
| Package | Version | Purpose |
|---|---|---|
| axios | ^1.5.0 | HTTP requests (e.g., chatbots). |
| cli-color | ^2.0.2 | Colored console logging. |
| cpu-stat | ^2.0.1 | CPU stats for status embeds. |
| discord-html-transcripts | ^3.1.3 | Ticket transcript generation. |
| discord.js | ^14.13.0 | Discord API client. |
| dotenv | ^16.4.5 | Environment variables. |
| ejs | ^3.1.10 | Dashboard templates. |
| express | ^4.19.2 | Web dashboard server. |
| moment | ^2.29.4 | Date/time formatting. |
| mongoose | ^7.1.1 | MongoDB ORM (if used). |
| quick.db | ^9.1.7 | File/SQLite DB wrapper. |
| quickmongo | ^5.2.0 | MongoDB driver for QuickDB. |
Install with: npm install
Ticker Boy/
βββ config.js # Bot config (DB, Discord, support)
βββ index.js # Main entrypoint
βββ package.json # Dependencies & scripts
βββ example.env # Env template
βββ LICENSE # BSD-3-Clause
βββ start.bat # Auto-install & start
βββ src/
β βββ commands/ # All commands (Admin, Misc, Owner, Ticket)
β β βββ Admin/settings.js # Main dashboard
β β βββ Misc/{help,invite,ping}.js
β β βββ Owner/{dbset,serverleave,serverlist}.js
β β βββ Ticket/{add,claim,close,create,delete,open,rename,transcript}.js
β βββ dashboard/ # Express web UI
β β βββ index.js
β β βββ public/ # Static files (CSS, HTML)
β β βββ views/ # EJS templates
β βββ events/ # Event handlers
β β βββ button/interactionCreate.js
β β βββ command/interactionCreate.js
β β βββ guild/{create,delete}.js
β β βββ menu/interactionCreate.js
β β βββ message/messageCreate.js
β β βββ modal/interactionCreate.js
β β βββ ready/ready.js
β β βββ status/ready.js
β β βββ ticket/interactionCreate.js
β βββ functions/ # Utilities
β β βββ chooseRandom.js
β β βββ database.js
β β βββ error.js
β β βββ errorMessage.js
β β βββ functions.js # Multi-purpose utils
β β βββ help.js
β β βββ loadCommand.js
β β βββ post.js
β β βββ ticket.js # Ticket core
β β βββ ... (20+ more)
β βββ handlers/ # Bootloaders
β β βββ 1-antivirus.js # (Missing in your upload?)
β β βββ 2-database.js
β β βββ 3-events.js
β β βββ 4-dashboard.js
β β βββ 5-commandHandler.js
β βββ locales/ # Translations
β β βββ en.json
β β βββ per.json
β βββ storage/ # Static data
β βββ colors.json
β βββ embed.json
β βββ emotes.json
β βββ languages.json
| Function | Input | Output | Description |
|---|---|---|---|
| chooseRandom(array) | array: any[] |
any |
Returns random item from array. |
| createORgetInvite(guild) | guild: Guild |
Invite | null |
Creates or fetches server invite. |
| DB.has(key) | key: string |
boolean |
Checks if DB key exists. |
| DB.get(key, def?) | key: string, def?: any |
any |
Gets value from DB (with default). |
| DB.set(key, val) | key: string, val: any |
Promise<void> |
Sets DB value. |
| DB.push(key, val) | key: string, val: any |
Promise<void> |
Appends to DB array. |
| DB.add(key, num) | key: string, num: number |
Promise<number> |
Increments DB number. |
| deleteResponse({interaction, message}) | Interaction/Message | void |
Deletes reply/message safely. |
| editResponse({interaction, message, data}) | Options obj | Message |
Edits interaction/message. |
| error(err) | err: Error |
void |
Logs error to console/webhook. |
| errorMessage(client, interaction, text) | Client, Interaction, string | void |
Sends styled error embed. |
| firstUpperCase(string) | string: string |
string |
Title-cases string (e.g., "hello" β "Hello"). |
| logMessage(client, interaction, channel, desc, reason, emote, file?) | Params obj | void |
Sends formatted log embed (with optional file). |
| loadCommand(dirname, type, commands) | Paths, Map | void |
Loads commands from folders. |
| post(data, type, color1, color2) | Params | void |
Colored console logger. |
| response(interaction, data) | Interaction, MessageOptions | Message |
Sends/edits response. |
| selectLanguage(lang) | lang: string |
Object |
Loads locale JSON. |
| sendGuildAlert({client, guild, ...}) | Options obj | Message |
Sends guild join/leave webhook. |
| ticket.create(client, interaction) | Client, Interaction | void |
Creates ticket channel. |
| ticket.close(client, interaction) | Client, Interaction | void |
Closes ticket, generates transcript. |
| ticket.claim(client, interaction) | Client, Interaction | void |
Claims ticket for staff. |
| checkPing(ms) | ms: number |
string |
Ping status emoji/text (e.g., "π’ Excellent"). |
- Node.js β₯16.9.0
- Discord Bot Token (Developer Portal)
- Optional: MySQL/MongoDB server
-
Clone Repo:
git clone https://github.com/Persian-Caesar/Ticker-Boy.git cd Ticker-Boy -
Install Dependencies:
npm install
-
Setup Environment (copy
example.envβ.env):token=YOUR_BOT_TOKEN prefix=! database_type=json # json/sql/mysql/mongodb # MongoDB: database_mongoURL=mongodb+srv://user:[email protected]/ # MySQL: database_msql_host=localhost database_msql_user=root database_msql_password=pass database_msql_database=tickerboy # Support: support_id=1054814674979409940 support_url=https://discord.gg/xh2S2h67UW webhook_url=YOUR_WEBHOOK_URL # For logging
-
Customize
config.js(optional):- Dashboard port/host
- Status activities
- Owners/VIP roles
- Invite links
-
Run Bot:
node index.js
Or:
start.bat(auto-install + run)
Invite Bot: Use links in config.js (no-perms, admin, default).
- source: Language, anti-crash, dashboard (port: 3000), DB type.
- discord: Token, prefix, status, invites, support (webhook, roles, owners).
- topgg: Vote page URL.
DB Types:
json: File-based (easiest).sql: SQLite (local).mysql: Remote MySQL.mongodb: Cloud MongoDB.
| Category | Command | Description | Permissions |
|---|---|---|---|
| Admin π¨βπΌ | /settings |
Interactive guild setup dashboard. | ManageChannels, ManageGuild |
| Misc π | /help [command] |
Bot info & command list. | SendMessages |
| Misc π | /invite |
Invite bot links. | SendMessages |
| Misc π | /ping |
Bot latency/ping. | SendMessages |
| Owner π | dbset <key> <value> |
Set DB value. | Owner IDs |
| Owner π | serverleave |
Leave small guilds (<50 members). | Owner IDs |
| Owner π | serverlist |
Paginated server list. | Owner IDs |
| Ticket π« | /add @user |
Add user to ticket. | ManageChannels |
| Ticket π« | /claim |
Claim ticket. | ManageChannels |
| Ticket π« | /close |
Close ticket. | SendMessages |
| Ticket π« | /create |
Create ticket. | SendMessages |
| Ticket π« | /delete |
Delete ticket. | ManageChannels |
| Ticket π« | /open |
Reopen ticket. | ManageChannels |
| Ticket π« | /rename <name> |
Rename ticket. | ManageChannels |
| Ticket π« | /transcript |
Generate HTML transcript. | ManageChannels |
Prefix: Configurable (default: empty for slash-only).
Guild data: guild_${guildId}
{
language: "en",
prefix: "!",
ticket_type: "Reason - Menu - UserTag",
ticket_claim: true,
admin_roles: ["roleId1"],
modlog: "channelId",
categories: { open: "catId", close: "catId" },
panel: {
channel: "channelId",
menu_options: [{ label: "Support", value: "Support", emoji: "π«" }]
},
tickets: [
{
channelId: "id",
channelName: "ticket-user",
user: "userId",
newUser: "addedUserId",
closed: false,
claimed: "claimerId"
}
]
}Global: totalCommandsUsed: number
- Enabled:
config.source.dashboard.on = true - URL:
http://localhost:3000(configurable port/host) - Tech: Express + EJS templates
- Features: Stats, commands, premium (WIP), invite
- Views:
/test, 404 handler - Static: CSS/JS in
/public
- Files:
src/locales/{en,per}.json - Default: English
- Per-Guild:
/settingsβ Language - Usage:
client.languages[lang].commands.help.embed1.title
- Anti-Crash:
process.on('unhandledRejection')β Webhook + Console. - Commands: Permission/cooldown checks with styled errors.
- Webhooks: Bugs/status/reports to support threads.
| Script | Usage |
|---|---|
npm start |
Run bot. |
start.bat |
Auto npm install && npm start. |
npm test |
Placeholder (no tests). |
- Fork repo
- Create branch:
git checkout -b feature/ticket-fix - Commit:
git commit -m "Fix: ticket claim bug" - Push:
git push origin feature/ticket-fix - Open PR
Guidelines:
- ESLint + Prettier
- JSDoc comments
- Unit tests for functions
- Mention Persian Caesar in credits
- Discord: Persian Caesar
- Report Bugs:
/settingsβ Report button (sends webhook). - Issues: GitHub Issues
- Vote: Top.gg
Copyright (c) 2021-2025, Sobhan-SRZA (mr.sinre) & Persian Caesar
- Developer: Sobhan-SRZA (mr.sinre)
- Team: Persian Caesar
- Libraries: Discord.js, QuickDB, Express, discord-html-transcripts
- Icons/Emotes: Custom Persian Caesar theme
β Star this repo if it helps!
Built with β€οΈ for Discord communities