2017 © Pedro Peláez
 

library exchange-rates

Retrieve currency exchange rate using several web services.

image

ipaulk/exchange-rates

Retrieve currency exchange rate using several web services.

  • Wednesday, March 22, 2017
  • by iPaulK
  • Repository
  • 0 Watchers
  • 0 Stars
  • 56 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

Exchange Rates

Retrieve currency exchange rate using several web services., (*1)

Available webservicess:

  1. WebserviceX.NET Data Protocol is a SOAP-inspired technology for reading, writing, and modifying information on the web.
  2. Fixer.io is a free JSON API for current and historical foreign exchange rates published by the European Central Bank.

Installation

$ composer require ipaulk/exchange-rates

Usage

Get specific exchange rate from Webservicex.net (by default), (*2)

use IPaulK\ExchangeRates\ExchangeRates as ExchangeRates;

$exchangeRates = new ExchangeRates();

/** @var float $value */
$value = $exchangeRates->getRate('USD', 'EUR');

Get specific exchange rate from fixer.io, (*3)

use IPaulK\ExchangeRates\ExchangeRates as ExchangeRates;

$exchangeRates = new ExchangeRates();
$exchangeRates->setProvider('fixerio');

/** @var float $value */
$value = $exchangeRates->getRate('USD', 'EUR');

Request specific exchange rates., (*4)

use IPaulK\ExchangeRates\ExchangeRates as ExchangeRates;

$exchangeRates = new ExchangeRates();

/** @var array $data */
$data = $exchangeRates->fetchRates('USD', ['EUR', 'GBP', 'JPY', 'RUB', 'ILS', 'AUD']);

The Versions

22/03 2017

dev-master

9999999-dev https://github.com/iPaulK/exchange-rates/

Retrieve currency exchange rate using several web services.

  Sources   Download

MIT

The Requires

 

php currency finance exchange rate webservicex

22/03 2017

1.1.0

1.1.0.0 https://github.com/iPaulK/exchange-rates/

Retrieve currency exchange rate using several web services.

  Sources   Download

MIT

The Requires

 

php currency finance exchange rate webservicex

15/03 2017

1.0.1

1.0.1.0 https://github.com/iPaulK/exchange-rates/

Retrieve currency exchange rate using several web services.

  Sources   Download

MIT

The Requires

 

php currency finance exchange rate webservicex

15/03 2017

1.0.0

1.0.0.0 https://github.com/iPaulK/exchange-rates/

Retrieve currency exchange rate using several web services.

  Sources   Download

MIT

The Requires

 

php currency finance exchange rate webservicex