A powerful, fully-configurable Discord bot for managing support and purchase tickets in your server. Users can create tickets, select payment methods, and receive logs. Staff can manage, notify, and close tickets with logs sent to both the user and a log channel.
- π Create support or purchase tickets via interactive buttons and dropdowns
- πΈ Role-based pricing and crypto address selection
- π‘οΈ Staff notification and ticket management
- π HTML log generation and delivery on ticket close
- βοΈ Everything configurable via a single
config.pyfile (no code edits needed!) - β³ Cooldown system to prevent spam
- π Security best practices
- Python 3.8+
discord.py(v2.x)
- Clone the repository:
git clone https://github.com/yourusername/discord-ticket-bot.git cd discord-ticket-bot - Install dependencies:
pip install -U discord.py
All settings are in config.py. You never need to edit the main code!
BOT_TOKEN: Your Discord bot token- Channel/Category IDs:
BUY_TICKET_CATEGORY_ID,SUPPORT_TICKET_CATEGORY_ID,INITIAL_MESSAGE_CHANNEL_ID,LOG_CHANNEL_ID ROLES: Role names and prices (EUR)CRYPTO_ADDRESSES: Crypto addresses for paymentsCOOLDOWN_MINUTES: Cooldown for pinging supportHELPER_ROLE_NAME: Name of your staff/helper role
TICKET_SELECT_OPTIONS: Options for the main ticket type select (label, value, description)BUY_ROLE_SELECT_OPTIONS: Options for the buy role select (label, value, description)PAYMENT_METHOD_SELECT_OPTIONS: Payment method select optionsCRYPTO_SELECT_OPTIONS: Crypto select optionsPING_SUPPORT_LABEL,NOTIFY_LABEL,CLOSE_LABEL,CREATE_TICKET_LABEL: Button labels
BOT_TOKEN = "YOUR_BOT_TOKEN_HERE"
BUY_TICKET_CATEGORY_ID = 123456789012345678
SUPPORT_TICKET_CATEGORY_ID = 123456789012345679
INITIAL_MESSAGE_CHANNEL_ID = 123456789012345680
LOG_CHANNEL_ID = 123456789012345681
ROLES = {"Silver": 5, "Gold": 10}
CRYPTO_ADDRESSES = {"USDT": "...", "BTC": "..."}
COOLDOWN_MINUTES = 5
HELPER_ROLE_NAME = "Helper"
TICKET_SELECT_OPTIONS = [
{"label": "Support", "value": "Support", "description": "Get help with an issue"},
{"label": "Buy", "value": "Buy", "description": "Purchase a role"}
]
# ...and so on for other optionsTip: Use emojis in your labels for extra flair! Example:
{ "label": "π Buy", ... }
python ticket.py- On startup, the bot posts a ticket creation message in your configured channel.
- Users click the button to create a support or purchase ticket.
- Staff can use these commands:
!refresh(Helper only): Reposts the ticket creation message!prules: Posts PayPal payment rules!notify @user(Helper only): Notifies a ticket owner via DM!close [@user](Helper only): Closes the ticket, sends the log to the user and log channel, and deletes the channel
- Never commit your real bot token to GitHub!
.gitignorealready excludesconfig.pyfor you- Limit bot permissions to only what is necessary
- Change role prices, crypto addresses, cooldowns, UI text, and select options in
config.py - For advanced changes, edit
ticket.py(not needed for most users)
Q: Can I use this bot in any language?
Yes! Just change the labels and descriptions in
config.py.
Q: Can I add more roles or payment methods?
Absolutely! Add more entries to the relevant lists in
config.py.
Q: How do I update the UI with emojis?
Add emojis to the
labelfields in your select/button options.
MIT
Made with β€οΈ for the Discord community!