Coder Social home page Coder Social logo

account's Introduction

Account API For Existing Customer


Spring Boot and ReactJS Application


This project provides to create account for existing customers.

Summary

The assessment consists of an API to be used for opening a new “current account” of already existing customers.

Requirements

• The API will expose an endpoint which accepts the user information (customerID, initialCredit).

• Once the endpoint is called, a new account will be opened connected to the user whose ID is customerID.

• Also, if initialCredit is not 0, a transaction will be sent to the new account.

• Another Endpoint will output the user information showing Name, Surname, balance, and transactions of the accounts.


The application has 2 apis

  • AccountAPI
  • CustomerAPI
POST /v1/account - creates a new account for existing customer
GET /v1/customer/{customerId} - retrieves a customer
GET /v1/customer - retrieves all customers

JUnit test coverage is 100% as well as integration tests are available.

Tech Stack


  • Java 11
  • Spring Boot
  • Spring Data JPA
  • Kotlin 1.5.0
  • Restful API
  • OpenAPI documentation
  • H2 In memory database
  • Docker
  • Docker compose
  • JUnit 5
  • ReactJS for frontend

Prerequisites


  • Maven
  • Docker

Run & Build


There are 2 ways of run & build the application.

Docker Compose

For docker compose usage, docker images already push to docker.io

You just need to run docker-compose up command


$PORT: 8080

$ cd account
$ docker-compose up

Maven

For maven usage, you need to change proxy value in the account-fe/package.json file by "http://localhost:8080" due to the default value has been settled for docker image network proxy.


$PORT: 8080

$ cd account/account-api
$ mvn clean install
$ mvn spring-boot:run

$ cd account/account-fe
$ npm install
$ npm start

Swagger UI will be run on this url

http://localhost:${PORT}/swagger-ui.html

account's People

Contributors

folksdev avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.