Skip to content

kanchan78/ExpenseTracker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ExpenseTrackerApi

A simple Expense tracker REST API

Screen.Recording.2024-03-10.at.12.31.24.PM.1.mov

About the API

An API for expense management. This project is built with Java, Spring Boot. The API main URL /expenses.

Features

This API provides HTTP endpoint's and tools for the following:

  • Create an expense: POST/expenses
  • Update an expense: PUT/expenses/{id}
  • Delete an expense (by id): DELETE/expenses/{id}
  • Find a unique expense by id: GET/expenses/{id}
  • Get all expenses: GET/expenses
  • Filter expense
    • By Name : GET/expenses/name?name={name}
    • By Category : GET/expenses/category?category={category}
    • By Date : GET/expenses/date?startDate={startDate}&endDate={endDate}
  • Pagination and Sorting

Expense Tracker API Documentation

Technologies used

This project was developed with:

  • Java 17
  • Spring Boot 3.2.2
  • Maven
  • Mysql

Compile and Package

The API also was developed to run with an jar. In order to generate this jar, you should run:

mvn package

This command will clean, compile and generate a jar at target directory, e.g. expensetrackerapi-0.0.1-SNAPSHOT.jar

Execution

This project uses Mysql database.

  • Create databseCreate database expensetracker.
  • Run Spring boot app it will automatically create table

Run

In order to run the API, run the jar as following:

java -jar expensetrackerapi-0.0.1-SNAPSHOT.jar --spring.profiles.active=dev

or

To test the application import `src/main/resources/templates/Expense Manager - REST API CRUD.postman_collection.json`  file on Postman App

Further Improvements:

  1. Adding security using spring security
  2. User specific expenses
  • Made with ❤
  • Don't forget to star it 🌟

Releases

No releases published

Packages

No packages published

Languages