agilord / ecb_fx

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

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ecb_fx

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

Usage

A simple usage example:

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

About

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

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Dart 100.0%