Basket API is a Spring Boot application that provides functionality for managing shopping carts and applying promotions.
The project is structured as follows:
-
src/main/java/com/example/basket
: Contains the Java source code for the application.controller
: Controllers responsible for handling HTTP requests.entity
: Entity classes representing data objects.exception
: Custom exception classes.request
: Request classes for API endpoints.response
: Response classes for API endpoints.service
: Service classes for business logic.Application.java
: The main application class.
-
src/test/java/com/example/basket
: Contains unit tests for the application.controller
: Controller test classes.service
: Service test classes.
-
pom.xml
: Maven configuration file for managing project dependencies and build settings.
Before you begin, ensure you have met the following requirements:
- Java Development Kit (JDK) 11 or later
- Maven (for building and managing dependencies)
To build the project, follow these steps:
-
Clone the repository to your local machine:
git clone https://github.com/berkinozturk/shopping-cart-API.git
-
Build the Project
mvn clean install
-
Running the Application
mvn spring-boot:run
The application will start, and you can access the API at http://localhost:8080.