API Reference Forex v0.2.1

View Source

Modules

Forex is a simple Elixir library that serves as a wrapper to the foreign exchange reference rates provided by the European Central Bank.

Since the ECB reference rates are usually updated at around 16:00 CET every working day we should cache the response.

Implementation of the Forex.Cache behaviour using DETS.

Implementation of the Forex.Cache behaviour using ETS.

This module provides curreny information and utility functions.

Exception for currency errors.

Exception for date errors.

This module is responsible for fetching the latest exchange rates from the European Central Bank (ECB) and parsing the XML response.

This module is responsible for defining the behaviour of the feed (HTTP) client.

The default HTTP API module for fetching the exchange rates from the European Central Bank (ECB). It implements the Forex.Feed.API behaviour and it uses Req as the HTTP client.

This module defines the behaviour of the parser that will be used to parse the XML response from the European Central Bank (ECB).

This module implements the Forex.Parser behaviour using the SweetXml library.

Exception for feed errors.

The Forex.Fetcher module is responsible for fetching the exchange rates from the cache or the feed on periodic intervals or on demand.

Exception for format errors.

Supervisor for the Forex supervision tree.

The Forex.Support module provides helper functions, for example, for formatting the exchange rates values.

Mix Tasks

Prints Forex tasks and their information.

Fetch and export the historic exchange rates from the European Central Bank to a file.

Fetch and export the latest exchange rates from the European Central Bank to a file.

Fetch and export the last ninety days exchange rates from the European Central Bank to a file.