This is a robust desktop & server-side application developed using Java (Swing + Selenium) to manage weekly food menus for KYK (Credit and Dormitories Institution) and automatically distribute them via WhatsApp.
This project features a modern GUI for data entry, a CLI mode for server environments, and smart automation capabilities using Selenium WebDriver.
- Menu Management: Enter, edit, and save daily menus (Breakfast & Dinner) via a user-friendly Java Swing interface.
- Smart CSV Integration: Support for Drag & Drop to load menus from
.csvfiles instantly. - WhatsApp Automation: Connects to WhatsApp Web, bypasses QR scanning (via session persistence), and sends formatted messages with emojis.
- Schedule & Timer: Schedule messages to be sent at a specific date and time, or send them instantly.
- Server Edition (CLI Mode): A fully functional Command Line Interface (
KykBotTerminal.bat) for running the bot on headless servers or via terminal. - Smart Navigation: Navigate through menu input fields using Arrow Keys (Up/Down) for faster data entry.
- Robust Media Handling: Fixed issues with loading application icons and logos from JAR files.
- Emoji Support: Improved message formatting with emoji support using System Clipboard integration (bypassing Selenium BMP errors).
Before running the project, ensure you have the following installed:
- Java JDK 21+: Required to run the application.
- Google Chrome: The bot uses the installed Chrome browser for automation.
- Maven: Used for dependency management (Selenium, FlatLaf, etc.) and building the project.
git clone https://github.com/SametCirik/WhatsApp-KYK-Bot.git
cd WhatsApp-KYK-BotThis project uses Maven. You don't need to download JARs manually. Simply run the following command in the project root to download all libraries (Selenium, etc.) defined in pom.xml:
mvn clean installTo create an executable JAR file with all dependencies included:
mvn clean packageThe output file will be located in the /target folder.
Run the JAR file directly or use the command below. This opens the visual interface where you can enter menus or drag-and-drop your CSV file.
java -jar target/Whatsapp-KYK-Bot.jar-
Enter Menu: Fill in the breakfast and dinner fields (Use Arrow Keys to navigate!).
-
Save/Load: Drag a
.csvfile into the designated area or save your manual entry. -
Start Bot: Click the "Botu Başlat" button to open the WhatsApp Scheduler.
For server environments where a GUI is not available or desired, use the provided batch script.
-
Navigate to the project folder.
-
Run
KykBotTerminal.bat. -
Enter the target WhatsApp Group Name when prompted.
-
The bot will run in the background and send today's menu.
This project uses Selenium 4.x, which includes "Selenium Manager". It automatically detects your installed Chrome version and downloads the matching ChromeDriver.
- Solution: Just keep your Google Chrome browser updated. Selenium handles the rest.
Ensure you are running the JAR file generated by mvn package. The resource loading logic checks both /bot/images/ and the root directory to find assets inside the JAR.
The bot uses a localized ChromeProfile folder to save your login session.
-
On the first run, you will need to scan the QR code.
-
On subsequent runs, the session is restored automatically (no scan needed).
Note: Ensure all Chrome windows are closed before running the bot to avoid profile lock errors.
As this is a personal project, external contributions are currently closed. However, feel free to fork the repository and experiment with the code.
Application Icon
2025-10-11-06-21-05.mp4
This project was developed by Samet Cırık.






