A complete ATM simulation system built using Spring Boot, Java, and a simple HTML/CSS/JS frontend.
This project supports card insertion, PIN authentication, checking balance, deposit, withdrawal, transaction history, and logout.
- Card insertion simulation
- PIN validation
- Generates session token
- Logout endpoint
- Check balance
- Deposit money
- Withdraw with validation
- View transaction history
- Fully implemented in HTML/CSS/JavaScript
- Calls backend through REST APIs
- Smooth action panels (Deposit/Withdraw/History)
- Java 17+
- Spring Boot
- Maven
- REST Controllers
- HTML
- CSS
- JavaScript (Fetch API)
src/ └── main/ ├── java/com/example/atm │ ├── AtmApplication.java │ ├── controller/ │ ├── service/ │ ├── model/ │ └── repository/ └── resources/ ├── static/ │ ├── index.html │ ├── script.js │ └── style.css └── application.properties
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/auth/login |
Login using cardNumber + PIN |
| POST | /api/auth/logout |
Logout |
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/account/balance |
Get account balance |
| POST | /api/account/deposit |
Deposit money |
| POST | /api/account/withdraw |
Withdraw money |
| GET | /api/account/transactions |
Get transaction list |
- Open project folder
- Let Maven import dependencies
- Run
AtmApplication.java
mvn spring-boot:run Backend will start on: http://localhost:8080
Frontend is automatically served from:
src/main/resources/static/index.html
This project is licensed under the MIT License (see LICENSE file).
If you like this project, consider giving it a ⭐ star on GitHub!