abstract-python
, the ExchangeRatesAPI
class is used to communicate with this API.
API Endpoints
Real-time exchange rates
Get real time exchange rates between multiple currencies
Convert currencies
Covert one currency to another using a base amount. e.g 5 USD to GBP
Historical exchange rates
Get a detailed
JSON
object of past exchange rates within a specified peiod.Supported currency codes
AbstractAPI supports ISO 4217 currency codes which can be found hereGet currency codes programmatically
Withabstract-python
you can get the supported currency codes as a Python List. See usage below:
Use case
If your app receives currency codes from users, you may need to validate these inputs before querying theExchangeRatesAPI
class.
See usage below:
Error messages
Refer to this page for all possible error messages you may encounter while using theExchangeRatesAPI
class.