Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/agilord/ecb_fx

Dart client for Foreign Exchange (FX) rates from the European Central Bank.
https://github.com/agilord/ecb_fx

Last synced: about 3 hours ago
JSON representation

Dart client for Foreign Exchange (FX) rates from the European Central Bank.

Awesome Lists containing this project

README

        

# ecb_fx

Foreign Exchange (FX) rates from the European Central Bank.
The rates refresh around 4 PM CET daily.

## Usage

A simple usage example:

````dart
import 'dart:async';

import 'package:ecb_fx/ecb_fx.dart';
import 'package:http_client/console.dart' as http;

Future main() async {
http.Client httpClient = new http.ConsoleClient();
EcbFxClient ecbFxClient = new EcbFxClient(httpClient);

EcbFxRates rates = await ecbFxClient.getCurrent();
print('Current USD/EUR rate: ${rates.getDecimal('USD')}');
}
````

## Links

- [ECB developer information](http://www.ecb.europa.eu/stats/policy_and_exchange_rates/euro_reference_exchange_rates/html/index.en.html#dev)
- [source code][source]
- contributors: [Agilord][agilord]

[source]: https://github.com/agilord/ecb_fx
[agilord]: https://www.agilord.com/