This project is a simple backend simulation of a WhatsApp chatbot built using Java Spring Boot.
https://chatbot-api-production-89cd.up.railway.app/webhook
-
REST API endpoint
/webhookto receive messages -
Accepts JSON input simulating WhatsApp messages
-
Responds with predefined replies:
- Hi → Hello
- Bye → Goodbye
- How are you → I'm a chatbot built with Spring Boot, and I'm doing great!
-
Logs all incoming messages in the console
- Java
- Spring Boot
- Maven
{
"message": "Hi"
}{
"reply": "Hello"
}- Clone the repository:
git clone https://github.com/your-username/chatbot-api.git- Navigate to the project:
cd chatbot-api- Run the application:
mvn spring-boot:run- Test using Postman:
http://localhost:8080/webhook
| Input | Output |
|---|---|
| Hi | Hello |
| Bye | Goodbye |
| How are you | I'm a chatbot built with Spring Boot, and I'm doing great! |
Mukul