GitHub - kumar9060/BankApp

๐Ÿฆ Bank Security Application

This is a Spring Boot-based backend banking application that provides secure RESTful APIs for managing user accounts, cards, investments, and admin functionalities. It integrates JWT-based authentication, role-based access control, and follows a modular structure separating concerns across controllers, services, repositories, DTOs, and security layers.


๐Ÿ” Features

  • โœ… JWT Authentication & Authorization
  • ๐Ÿ‘ค Role-based Access (Admin & Customer)
  • ๐Ÿ’ผ Account Management
  • ๐Ÿ’ณ Card Services
  • ๐Ÿ“ˆ Investment Tracking
  • ๐Ÿงผ DTO & Layered Architecture
  • ๐Ÿ†• Bootstrap Default Admin User on Startup
  • ๐Ÿ” Get User by ID
    • Admin can view users of all roles except other admins
    • Customers can only view their own details

๐Ÿ“ Project Structure

com.security.bank
โ”œโ”€โ”€ accounts
โ”œโ”€โ”€ admin
โ”œโ”€โ”€ cards
โ”œโ”€โ”€ config
โ”œโ”€โ”€ dto
โ”œโ”€โ”€ entity
โ”œโ”€โ”€ investments
โ”œโ”€โ”€ jwt
โ”œโ”€โ”€ repository
โ”œโ”€โ”€ Root
โ”œโ”€โ”€ security
โ”œโ”€โ”€ service
โ”œโ”€โ”€ user
โ””โ”€โ”€ BankApplication.java

๐Ÿš€ Getting Started

Prerequisites

  • Java 17+
  • Maven
  • MySQL or H2
  • Postman for testing

Run Locally

git clone https://github.com/kumar9060/BankApp.git
cd BankApp
./mvnw spring-boot:run

API Testing

Use Postman or Swagger to test APIs (like /auth/login, /account/create, etc.)


๐Ÿ™Œ Contribution

Pull requests are welcome. For major changes, please open an issue first.


๐Ÿ“ง Contact

Made ๐Ÿ’ป by Vikas Kumar