/eurorates

Java Micronaut HTTP Client for European Central Bannk's euro foreign exchange reference rates API

Primary LanguageGroovy

Micronaut Java library to consume the Euro foreign exchange reference rates

Euro Foreign Exchange Reference Rates API Micronaut Java Library

This project is a Java libray to consume the Euro foreign exchange reference rates API. It is built with the Micronaut Framework and you can use it in a Micronaut app or as a standalone library.

Dependency snippet

To use it with https://gradle.org[Gradle]:

implementation 'com.softamo:eurorates:XXXX'

To use it with https://maven.apache.org[Maven]:

<dependency>
    <groupId>com.softamo</groupId>
    <artifactId>eurorates</artifactId>
    <version>xxx</version>
    <type>pom</type>
</dependency>

Usage

If you want to use the library in Micronaut application, the library registers a bean of type como.softamos.eurorates.EuroRatesApi in the Micronaut's application context.

You can use the library without a Micronaut Application Context. In that case, to obtain a EuroRatesApi do:

EuroRatesApi euroRatesApi = new ManualEuroRatesApi();

The api contains methods to obtain the current rates, historic rates and last 90 days rates.

Build

This library uses https://gradle.org[Gradle].

It uses the plugins:

Release instructions

snapshot:

  • Make sure version ends with -SNAPSHOT
  • ./gradlew publish

release:

  • bump up version
  • Tag it. E.g. v1.0.0
  • ./gradlew publishToSonatype closeSonatypeStagingRepository

Go to https://s01.oss.sonatype.org/#stagingRepositories and release repository.