Currencies API
General:
Basics:
Parameters in the url should all be encoded and all data sent should be UTF-8
MAX number of requests per minute is set to 200.
When the limit is hit an error with code 429 is returned, with the header "Retry-After" containing the number of seconds you have to wait for your next request.
When the limit is hit an error with code 429 is returned, with the header "Retry-After" containing the number of seconds you have to wait for your next request.
Headers:
Accept: application/json Content-Type: application/json
Errors:
| Code | Description |
|---|---|
| 900001 | Credentials don't match |
| 900101 | Common error |
| 900429 | Too many requests |
| 900401 | Error when getting a currency |
{
"errorCode" : 900101,
"errorMessage" : "Something went wrong on the server",
"errorField" : null,
"errorData" : null
}
Currencies API:
Currencies
Get currency based on currency-code with base
GETUrl: /base/{base_currency_code}/currency/{currency_code}
Headers:
Accept: application/json or application/xml
Get a valid currencies with a base currency to establish exchange rate
Body:
Successfull response:
{ "country": "country", "currencyChar": "currencyChar", "rate": 1379.1694561634415, "currency": "currency" }
Get currencies
GETUrl:
Headers:
Accept: application/json or application/xml
Get a list of valid currencies
Body:
Successfull response:
{ "baseCurrency": "baseCurrency", "currencies": [{ "country": "country", "currencyChar": "currencyChar", "rate": 911.4600846929554, "currency": "currency" }] }
Get currencies with base
GETUrl: /base/{currency_code}
Headers:
Accept: application/json or application/xml
Get a list of valid currencies with a base currency to establish exchange rate
Body:
Successfull response:
{ "baseCurrency": "baseCurrency", "currencies": [{ "country": "country", "currencyChar": "currencyChar", "rate": 5213.544787925961, "currency": "currency" }] }
Classes:
CurrenciesResponseDto
| Field | Type | Description | Default | Mandatory | Accepted values | Example values | Access |
|---|---|---|---|---|---|---|---|
| currencies | List | R | |||||
| baseCurrency | String | R |
CurrencyDto
| Field | Type | Description | Default | Mandatory | Accepted values | Example values | Access |
|---|---|---|---|---|---|---|---|
| currency | String | R | |||||
| currencyChar | String | R | |||||
| country | String | R | |||||
| rate | double | R |