Skip to content

Dastya/currency_management_API

Repository files navigation

Exchange Rate API

This project implements an API that retrieves exchange rate data from various providers and stores it in a local database. It provides two methods for retrieving exchange rate data:

  1. /currency/average - Retrieves a list of exchange rates for all sources, including the average market rate.
  2. /currency/average_by_date - Retrieves a list of average exchange rates for all sources for a specified period.

API Providers

This project supports the following API providers:

For each of these providers, a common interface has been implemented, with separate implementations for each provider.

Data Synchronization

The API periodically synchronizes data with the API providers using a cron job. This ensures that the local database always has the most up-to-date exchange rate data.

Technologies Used

This project was developed using the following technologies:

  • Java/Kotlin
  • Tomcat
  • Spring Boot
  • Hibernate
  • PostgreSQL
  • Git
  • Swagger
  • Gradle

Running the Project

To run the project, you will need to perform the following steps:

  1. Clone the project repository: git clone https://github.com/Dastya/currency_management_API.git
  2. Set up a PostgreSQL database and create the necessary tables
  3. Update the database configuration in src/main/resources/application.properties to point to your database.
  4. Build the project using Gradle: ./gradlew build
  5. Start the API using the command java -jar build/libs/currency_exchange_daemon.jar
  6. Navigate to http://localhost:8080/swagger-ui.html to access the API documentation using Swagger.

API Documentation

The API is documented using Swagger. To view the documentation, navigate to http://localhost:8080/swagger-ui.html after starting the API.

About

Test task for TAG Soft

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published