Giter Club home page Giter Club logo

exchanger_system's Introduction

exchanger_system

Hello, this is a simple currency exchange API developed in Kotlin with Javalin. Made with Ubuntu 20.10.

All app related dependencies are listed in pom.xml.

to run the app, execute Main.kt.

Database

In this system, the chosen database was a Postgres v13.4. I used a docker to set it up and get it running and docker compose to simplify configuration.

With a docker installation and a connection to docker hub simply download the postgres image and them run the docker-compose up command in the docker-compose.yml file level

API

After running the app, the local port 7000 will be ready to receive requests.

Conversion endpoint

Send a POST request to localhost:7000/transaction with the following pattern:

{
  "key": <STRING>,
  "from": <STRING>,
  "to": <STRING>,
  "value": <NUMBER>
}

For example, if you want to convert 149,23 BRL to EUR try:

{
    "key": "user1",
    "from": "BRL",
    "to": "EUR",
    "value": 149.23
}

The key field is used to identify the user that made the request

Transaction history endpoint

Send a GET request to localhost:7000/transaction/:key to get the history of transactions from that user. The parameter key is used for identification.

For example, to get the history of transactions of the user wit key josuke_higashikata send a GET request to:

    localhost:7000/transaction/josuke_higashikata

exchanger_system's People

Contributors

nobreconfrade avatar

Watchers

 avatar  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.