/E-commerce-Backend

This REST API was created for an E-Commerce Project. This API handles all of the basic CRUD functions of an E-commerce Application platform, including validation at each stage.

Primary LanguageJava

E-commerce Backend

This REST API was created for an E-Commerce Project. This API handles all of the basic CRUD functions of an E-commerce Application platform, including validation at each stage.

About the Project

  • You can see API Documentation at API root end Point via Swagger.
  • Authentication and validation for customer and admin was made using the Session UUID.
  • Lombok library used so I minimized boilerplate code in the project.

Tech Stack

  • Java
  • Springboot
  • Spring Data JPA
  • Hibernate
  • Lombok
  • MySQL
  • Swagger
  • PostMan

Modules

Admin Module operations

  • Add new products
  • Manage product quantities
  • All of the Order's management
  • Search by customer details ( name, e-mail, phone, id )
  • Customer management
  • Search by order
  • Admin and Customers ( different login )

Customer Module operations

  • Login and Register
  • See cart details and total price
  • Add to cart
  • Make a purchase, and track its status
  • Search by category
  • Payment

API Root End Point

http://localhost:8880/swagger-ui/

E-R Diagram

e-r


API Module End Points

Sample API Response for Admin Login

POST localhost:8080/admin/login

  • Request Body
 

{
  "adminId": 15,
  "password": "berkbeleli"
}

  • Response
 

   CurrentAdminSession(userId=15, uuid=E4Jiid, localDateTime=2022-12-21T00:39:58.270034)


Swagger UI

Screenshot 2022-12-21 at 12 43 46 AM


Admin Controller

Screenshot 2022-12-21 at 12 44 53 AM


Customer Controller

Screenshot 2022-12-21 at 12 45 17 AM


Order Controller

Screenshot 2022-12-21 at 12 45 35 AM


Product Controller

Screenshot 2022-12-21 at 12 45 46 AM