Skip to content

A Discord bot that creates and manages sticky messages with advanced features like custom embeds, variables, and automatic cleanup functionality.

License

Notifications You must be signed in to change notification settings

ItsMeRioooo/Sticky-Discord-Bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎵 Sticky Discord Bot

A powerful Discord bot that creates persistent sticky messages with dynamic content including music bot availability tracking.

✨ Features

  • Sticky Messages: Auto-reposting messages that stay at the bottom of channels
  • Music Bot Tracking: Track and display available music bots not in voice channels
  • Dynamic Variables: Server name, time, date, member count, and more
  • Role-Based Exclusions: Exclude specific bots from tracking with roles
  • Rich Embeds: Beautiful embed support with custom colors and footers
  • Real-Time Updates: Automatic updates when bot status changes
  • Simple Commands: Easy-to-use slash commands

🚀 Quick Start

Prerequisites

  • Node.js 16.9.0 or higher
  • Discord Bot Token
  • Discord Application with Bot permissions

Installation

  1. Clone the repository

    git clone https://github.com/ItsMeRioooo/Sticky-Discord-Bot.git
    cd Sticky-Discord-Bot
  2. Install dependencies

    npm install
  3. Create environment file

    cp .env.example .env
  4. Add your bot token to .env

    DISCORD_TOKEN=your_bot_token_here
  5. Start the bot

    npm start

📋 Commands

Sticky Message Commands

  • /sticky - Set a sticky message in a channel
  • /unsticky - Remove a sticky message from a channel
  • /stickies - List all sticky messages in the server
  • /help - Show help information
  • /cleanup - Force cleanup ALL bot messages (Admin only)

Bot Management Commands (Admin Only)

  • /addbot - Add a bot to the tracking list
  • /removebot - Remove a bot from the tracking list
  • /bots - List all tracked bots
  • /setrole - Set role to exclude bots from VC tracking
  • /vcbots - Show bots currently in voice channels

🔧 Variables

Use these variables in your sticky messages:

Variable Description
{server_name} Server name
{channel_name} Channel name
{member_count} Server member count
{time} Current time
{date} Current date
{datetime} Date and time
{not in a vc} List of available music bots
{not_in_vc} Same as above (alternative)
{bots_not_in_vc} Same as above (alternative)

🎨 Example Usage

Basic Sticky Message

/sticky content:Welcome to {server_name}! We have {member_count} members.

Music Bot Availability

/sticky content:{not in a vc}

This will display:

**Available Music Bots:**
@MusicBot1 (m!play)
@MusicBot2 (r!play)

Or when no bots are available:

**There are currently no available Music Bots. Please wait for one to become available!**

⚙️ Bot Permissions

Your bot needs these permissions:

  • Send Messages
  • Manage Messages
  • Embed Links
  • Read Message History
  • Use Slash Commands
  • View Channels

📁 File Structure

├── index.js              # Main bot file
├── package.json          # Dependencies
├── .env                  # Environment variables (create this)
├── .gitignore           # Git ignore file
├── bot-config.json      # Bot configuration (auto-generated)
├── bot-info.json        # Tracked bots list (auto-generated)
├── sticky-data.json     # Sticky messages data (auto-generated)
└── README.md            # This file

🔧 Configuration

The bot automatically creates configuration files:

  • bot-config.json - Stores VC exclusion role
  • bot-info.json - Stores tracked bot list
  • sticky-data.json - Stores sticky message data

🛠️ Development

Adding New Features

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Test thoroughly
  5. Submit a pull request

Code Style

  • Use ES6+ features
  • Follow existing code patterns
  • Keep functions small and focused
  • Add error handling

📝 License

This project is licensed under the MIT License - see the LICENSE file for details.

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

📞 Support

If you need help or have questions:

  • Open an issue on GitHub
  • Check the help command: /help

🎯 Roadmap

  • Web dashboard
  • Custom prefix support
  • Advanced scheduling
  • Multi-server management
  • Database integration

Made with ❤️ by ItsMeRioooo

About

A Discord bot that creates and manages sticky messages with advanced features like custom embeds, variables, and automatic cleanup functionality.

Resources

License

Stars

Watchers

Forks

Packages

No packages published