Skip to content

amirshakeri8080/Bot-Management-Dashboard

Repository files navigation

Bot Management Dashboard

Developed by TheRealPourya Team

A modern, production-ready Windows desktop application for managing and running multiple bots (Python, Node.js, or any command-line based bots) from a beautiful web-based dashboard.

Version Platform License


✨ Features

  • πŸ€– Manage Multiple Bots - Add, edit, delete, and organize unlimited bots
  • ▢️ Run in PowerShell - Execute bots in separate PowerShell windows
  • πŸ“ Quick Folder Access - Open bot directories directly from the dashboard
  • πŸ“Œ Pin Important Bots - Keep frequently used bots at the top
  • πŸ” Search & Filter - Quickly find bots by name, path, command, or notes
  • 🎨 Modern UI - Beautiful, responsive interface with dark/light theme
  • πŸ–±οΈ Drag & Drop - Reorder bots with intuitive drag and drop
  • πŸ’Ύ Persistent Storage - All settings saved locally in JSON format
  • πŸš€ Run All Bots - Start multiple bots simultaneously with one click
  • πŸ“Š Status Tracking - See which bots are running or stopped
  • 🎯 Zero Configuration - Works out of the box after installation

πŸ“‹ Requirements

  • Windows 10 or Windows 11
  • Python 3.8 or higher (for running from source)
  • PowerShell (pre-installed on Windows)

πŸš€ Quick Start (Running from Source)

1. Install Dependencies

cd botManager
pip install -r requirements.txt

2. Run the Application

Option A: Using Python directly

python app.py

Option B: Using the batch file

run.bat

The dashboard will automatically open in your default web browser at http://127.0.0.1:5000


πŸ“¦ Building as .EXE (Standalone Executable)

To create a single .exe file that can be distributed to end-users:

1. Install PyInstaller

pip install pyinstaller

2. Build the Executable

Option A: Using the spec file (Recommended)

pyinstaller BotManager.spec

Option B: Using command line

pyinstaller --onefile --name BotManager --add-data "templates;templates" --add-data "static;static" --hidden-import flask --hidden-import flask_cors --console app.py

3. Locate Your Executable

After building, find your executable at:

botManager\dist\BotManager.exe

4. Distribution

You can now distribute BotManager.exe to any Windows 10/11 computer. No Python installation required on the target machine!

Note: The data folder will be automatically created at:

C:\Users\<USERNAME>\BotManager\data\

πŸ“– User Guide

Adding a New Bot

  1. Click the "Add Bot" button
  2. Fill in the required fields:
    • Bot Name: A descriptive name for your bot
    • Folder Path: Full path to the bot's directory (e.g., C:\Bots\MyBot)
    • Run Command: Command to execute (e.g., python main.py, node index.js, npm start)
    • Notes: Optional description or important information
    • Pin: Check to keep this bot at the top
  3. Click "Add Bot" to save

Running Bots

  • Single Bot: Click the green "Run" button on any bot card
  • All Bots: Click the "Run All" button in the action bar
  • Each bot opens in its own PowerShell window
  • The bot status will update to show "Running"

Managing Bots

  • Edit: Click the yellow edit icon (✏️) to modify bot details
  • Delete: Click the red trash icon (πŸ—‘οΈ) to remove a bot
  • Open Folder: Click the blue folder icon (πŸ“‚) to open the bot's directory
  • Pin/Unpin: Click the pin icon (πŸ“Œ) to toggle pinned status
  • Reorder: Drag and drop bot cards to rearrange them

Search and Filter

Use the search bar to quickly find bots by:

  • Bot name
  • Folder path
  • Run command
  • Notes content

Theme

Toggle between light and dark mode using the sun/moon icon in the header.


πŸ—‚οΈ Project Structure

botManager/
β”œβ”€β”€ app.py                  # Flask backend server
β”œβ”€β”€ requirements.txt        # Python dependencies
β”œβ”€β”€ run.bat                 # Windows batch launcher
β”œβ”€β”€ BotManager.spec         # PyInstaller configuration
β”œβ”€β”€ README.md               # This file
β”œβ”€β”€ templates/
β”‚   └── index.html          # Main dashboard UI
β”œβ”€β”€ static/
β”‚   β”œβ”€β”€ css/                # (Reserved for custom CSS)
β”‚   └── js/                 # (Reserved for custom JS)
└── data/
    └── bots.json           # Bot configuration storage

πŸ’Ύ Data Storage

Bot configurations are stored in:

C:\Users\<USERNAME>\BotManager\data\bots.json

The file is automatically created on first run with example bots. You can manually edit this JSON file if needed.

Bot JSON Structure

{
  "id": "unique-uuid",
  "name": "Bot Name",
  "path": "C:\\Path\\To\\Bot",
  "command": "python main.py",
  "notes": "Optional description",
  "pinned": false,
  "order": 0
}

πŸ”§ Configuration

Changing the Server Port

Edit app.py, line at the bottom:

app.run(host="127.0.0.1", port=5000, debug=False)

Change 5000 to your desired port.

Disabling Auto-Browser Launch

Comment out or remove this line in app.py:

threading.Thread(target=open_browser, daemon=True).start()

πŸ› Troubleshooting

"Python not found" Error

Make sure Python is installed and added to your system PATH:

  1. Download Python from python.org
  2. During installation, check "Add Python to PATH"
  3. Restart your terminal/command prompt

Bot Won't Run

  • Verify the Folder Path exists and is correct
  • Check that the Run Command is valid for that directory
  • Ensure necessary dependencies are installed in the bot's environment
  • Check the PowerShell window for error messages

Port Already in Use

If port 5000 is occupied:

  1. Close the application using that port
  2. Or change the port in app.py (see Configuration section)

.EXE Build Fails

  • Ensure all dependencies are installed: pip install -r requirements.txt
  • Try upgrading PyInstaller: pip install --upgrade pyinstaller
  • Check that templates and static folders exist

Browser Doesn't Open Automatically

Manually navigate to: http://127.0.0.1:5000 in your web browser


πŸ› οΈ Development

Tech Stack

  • Backend: Python 3, Flask, Flask-CORS
  • Frontend: HTML5, TailwindCSS, Alpine.js
  • Drag & Drop: SortableJS
  • Icons: Font Awesome 6
  • Packaging: PyInstaller

Running in Development Mode

To enable Flask debug mode, edit app.py:

app.run(host="127.0.0.1", port=5000, debug=True)

Adding Custom Styles

Add CSS files to static/css/ and link them in templates/index.html

Adding Custom JavaScript

Add JS files to static/js/ and include them in templates/index.html


πŸ” Security Notes

  • This application is designed for local use only
  • The Flask server binds to 127.0.0.1 (localhost) by default
  • Do NOT expose this server to the internet without proper security measures
  • Bot commands are executed directly in PowerShell - only add trusted bots

πŸ“ API Endpoints

The dashboard uses the following REST API:

Method Endpoint Description
GET /api/bots Get all bots
POST /api/bots Add a new bot
PUT /api/bots/:id Update a bot
DELETE /api/bots/:id Delete a bot
POST /api/bots/:id/run Run a specific bot
POST /api/bots/:id/stop Stop a running bot
POST /api/bots/:id/open-folder Open bot folder
POST /api/bots/run-all Run all bots
POST /api/bots/reorder Reorder bots

🀝 Contributing

This is a complete, production-ready application. Feel free to:

  • Fork and modify for your needs
  • Add new features
  • Improve the UI/UX
  • Submit pull requests

πŸ“„ License

MIT License - Feel free to use, modify, and distribute.


πŸ‘¨β€πŸ’» Developer

TheRealPourya Team

Built with ❀️ for the bot management community.


🎯 Version History

v1.0.0 (Current)

  • βœ… Initial release
  • βœ… Full CRUD operations for bots
  • βœ… PowerShell execution support
  • βœ… Dark/Light theme
  • βœ… Drag & drop reordering
  • βœ… Search and filter
  • βœ… Pin/Unpin functionality
  • βœ… Run all bots feature
  • βœ… Status tracking
  • βœ… Modern responsive UI

πŸš€ Future Enhancements (Ideas)

  • Bot scheduling (run at specific times)
  • Log viewer for bot output
  • Custom bot icons
  • Import/Export bot configurations
  • Multi-language support
  • System tray integration
  • Auto-restart on crash
  • Resource monitoring (CPU, RAM)
  • Bot grouping/categories

Enjoy managing your bots! πŸ€–

About

A modern, production-ready Windows desktop application for managing and running multiple bots (Python, Node.js, or any command-line based bots) from a beautiful web-based dashboard.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors