This service is used to retrieve one or more exchange rates for countries from the approved HMRC monthly exchange rates
- A call is made to the
/rates/:date
endpoint with a valid date and one or more currency codes in the query string. - A
200
response with JSON data containing the start and end date for the rates, the currency code and the rate for that currency code.
GET /currency-conversion/rates/:date
GET -> /currency-conversion/rates/2019-03-21?cc=USD
[
{
"startDate": "2019-03-01",
"endDate": "2019-03-31",
"currencyCode": "USD",
"rate": "1.3064"
}
]
NB: If an exchange rate file cannot be found, an error will be logged and a WARNING 299 - Date out of range
will be in the response headers.
To run the tests locally, simply run ./run_all_tests.sh
This code is open source software licensed under the Apache 2.0 License.