An open API service indexing awesome lists of open source software.

https://github.com/akhilesh664/bankingsystem

๐Ÿฆ A robust Banking System built with Core Java, Spring Boot, MySQL, and Spring Data JPA, offering secure user authentication, account management, fund transfers, transaction history, and real-time balance checks. It features REST APIs for seamless integration, role-based access control, automated notifications, and efficient data handling. ๐Ÿš€
https://github.com/akhilesh664/bankingsystem

java mysql rest springboot springdata-jpa springframework springsecurity

Last synced: 8 months ago
JSON representation

๐Ÿฆ A robust Banking System built with Core Java, Spring Boot, MySQL, and Spring Data JPA, offering secure user authentication, account management, fund transfers, transaction history, and real-time balance checks. It features REST APIs for seamless integration, role-based access control, automated notifications, and efficient data handling. ๐Ÿš€

Awesome Lists containing this project

README

          

#

๐Ÿฆ Banking System

A robust and secure **Banking System** built using **Core Java**, **Spring Boot**, **MySQL**, and **Spring Data JPA**. This project provides RESTful APIs for handling user authentication, account management, fund transfers, transaction history, and real-time balance checks. It also supports role-based access and automated notifications.

---

## ๐Ÿš€ Features

โœ… Secure User Registration & Login (JWT-based)
โœ… Account Creation & Management
โœ… Fund Transfer between Accounts
โœ… View Transaction History
โœ… Real-Time Balance Check
โœ… Role-Based Access Control (Admin / User)
โœ… RESTful API Architecture
โœ… Input Validation & Error Handling
โœ… Automated Email or Console Notifications
โœ… MySQL Integration with JPA/Hibernate

---

## ๐Ÿงฐ Tech Stack

- **Java** (Core Java, Java 17 or above)
- **Spring Boot**
- **Spring Data JPA**
- **MySQL**
- **Hibernate**
- **JWT for Authentication**
- **Lombok**
- **Maven**
- **Postman** for API Testing

---

## ๐Ÿ“ Project Structure

```
src
โ””โ”€โ”€ main
โ”œโ”€โ”€ java
โ”‚ โ””โ”€โ”€ com.bankingsystem
โ”‚ โ”œโ”€โ”€ controller
โ”‚ โ”œโ”€โ”€ service
โ”‚ โ”œโ”€โ”€ repository
โ”‚ โ”œโ”€โ”€ model
โ”‚ โ””โ”€โ”€ config
โ””โ”€โ”€ resources
โ”œโ”€โ”€ application.properties
โ””โ”€โ”€ data.sql
```

---

## ๐Ÿ› ๏ธ Getting Started

### โœ… Prerequisites

- Java 17+
- Maven
- MySQL Server

### ๐Ÿšฆ Steps to Run

1. **Clone the Repository**
```bash
git clone https://github.com/your-username/Banking-System.git
cd Banking-System
```

2. **Set up MySQL Database**
```sql
CREATE DATABASE banking_system;
```

3. **Configure `application.properties`**
```properties
spring.datasource.url=jdbc:mysql://localhost:3306/banking_system
spring.datasource.username=root
spring.datasource.password=your_password
spring.jpa.hibernate.ddl-auto=update
spring.jpa.show-sql=true
```

4. **Build and Run**
```bash
mvn spring-boot:run
```

5. **Test with Postman**
- Base URL: `http://localhost:8080/api`

---

## ๐Ÿ“ฎ API Endpoints

| Method | Endpoint | Description |
|--------|---------------------------|------------------------------|
| POST | /auth/register | Register new user |
| POST | /auth/login | Login and get JWT token |
| GET | /accounts/{id} | Get account details |
| POST | /accounts/transfer | Transfer funds |
| GET | /transactions/{userId} | Transaction history |
| GET | /accounts/balance/{id} | Real-time balance check |

---

## ๐Ÿ” Role-Based Access

| Role | Access Permissions |
|-------|----------------------------------------------|
| Admin | View all users, transactions, delete users |
| User | Manage own account, transfer, view history |

---

## ๐Ÿงช Testing

- Use **JUnit** and **Mockito** for service/controller layer testing.
- Coverage for login, transfer, and exception handling.

---

## ๐Ÿ™Œ Acknowledgements

- Spring Boot Documentation
- MySQL Community
- Baeldung & StackOverflow

---

## ๐Ÿ“ฌ Contact

**Akhilesh Ojha**
๐Ÿ“ง [akhil00664@gmail.com](mailto:akhil00664@gmail.com)
๐ŸŒ [LinkedIn](https://www.linkedin.com/in/theakhileshojha/)

---

## ๐Ÿ“„ License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.