API Responses

Successful Responses

When a request is successful, the following JSON object is returned:

Attribute Value Explanation
status ok You can check status for success (ok) or failure (fail)
code 0 Have a look at Return codes table
result object result is a JSON object containing the following attributes:
  • updated_at: Last time when the data was updated
  • value: Exchange rate
  • base: Currency base
  • target: Currency target

Failure Responses

When a request is failed, a JSON object is returned as well, but with different attributes:

Attribute Value Explanation
status fail You can check status for success (ok) or failure (fail)
code 1-6 Have a look at Return codes table
message string Error explanation

Return codes

Code Status Message
0 ok
1 fail Amount should be between 0 and 999999999
2 fail Currencies are not valid
3 fail Limit Reached (10 requests per day). Please adquire a license key
4 fail The api key is not valid
5 fail Your api key has expired. Please renew it
6 fail Currency codes are the same
7 fail Invalid Date