Giter VIP home page Giter VIP logo

fixer's Introduction

Fixer - Important Announcement

We are happy to announce the complete relaunch of fixer.io into a more stable, more secure, and much more advanced currency & exchange rate conversion API platform. While the core structure of our API remains unchanged, all users of the legacy Fixer API will be required to sign up for a free API access key and perform a few simple changes to their integration. To learn more about the changes that are required, please jump to the „Required Changes“ section below.

Required Changes to Legacy Integrations (api.fixer.io)

As of March 6th 2018, the legacy Fixer API (api.fixer.io) is deprecated and a completely re-engineered API is now accessible at https://data.fixer.io/api/ The core structure of the old API has remained unchanged, and you will only need to perform a few simple changes to your integration.

1. Get a Free Fixer Access Token

Go to fixer.io and create an account. After signup, you will receive an access token immediately. If you plan on using less than 1000 requests per month, your account will be completely free. If you need more or want to use some of our new features, you’ll need to choose one of the paid options.

2. Replace API URL and add Access Key

The new API comes with a new endpoint and now requires an access key in the GET URL. Please change your API URL from api.fixer.io to https://data.fixer.io/api and attach your newly generated access key to the URL as a GET parameter named „access_key“.

Example

If your old API Call was https://api.fixer.io/latest then your new integration should point to: https://data.fixer.io/api/latest?access_key=YOUR_ACCESS_KEY

New Features

Although the core structure of the fixer API remains unchanged, we added a whole lot of improvements, 100+ more currencies, and many more features to the new Fixer API. You can read more about all new features on the new fixer.io website. Here’s a list of the most important ones:

  • Fixer is still free! Although we now offer a set of premium plans for more advanced users, the basic API features (e.g. getting the latest and historical exchange rates) remain completely free of charge. Minor limitations include our new 1000 requests/month limit and EUR being the only available base currency for customers using a free account. If you need more than 1000 requests per month or want to use all 170 available base currencies, you’ll need to choose one of the paid plans starting at only $10 per month.

  • Over 100 Additional Currencies The new Fixer API now supports over 100 additional currencies, bumping the total available currencies for conversion to 170.

  • More Reliable Data Sources & Updates every minute The old Fixer API was limited to currency data from the European Central Bank, which updates only once every day. The new API comes with 16+ connected data sources and data updates every hour, 10-minutes, or even every minute - depending on which subscription plan you choose.

  • More Endpoints The new fixer API has over 3 new endpoints, including a Direct Conversion endpoint, Time-Series conversion endpoint, and allows you to see the fluctuation of a specfic currency using our new Fluctuation endpoint. To learn more about all the new features, please head over to the API documentation at fixer.io/documentation

Next Steps

- Discontinuation of the old API

The old, deprecated Fixer API will be discontinued on June 1st, 2018. Please make sure to adjust your existing implementation to point to the new API endpoint (see above) as soon as possible in order to prevent service disruption on the planned shutdown date. In case you have any questions, please feel free to contact us using the email address below.

- Need help? Please get in touch

It’s very important for us to ensure a smooth transition to the new API Endpoint for all of our users. If you are a developer who has published a third-party plugin with Fixer, we recommend you to get in touch and share this announcement with your user base. If you need any help or have questions about the transition, please reach out at [email protected]

Travis

Fixer is a free API for current and historical foreign exchange rates published by the European Central Bank.

A public instance of the API lives at https://api.fixer.io. Alternatively, you can run privately with the provided Docker image.

Rates are updated around 4PM CET every working day.

Usage

Get the latest foreign exchange rates.

GET /latest

Get historical rates for any day since 1999.

GET /2000-01-03

Rates are quoted against the Euro by default. Quote against a different currency by setting the base parameter in your request.

GET /latest?base=USD

Request specific exchange rates by setting the symbols parameter.

GET /latest?symbols=USD,GBP

The primary use case is client side. For instance, with money.js in the browser

let demo = () => {
  let rate = fx(1).from("GBP").to("USD")
  alert("£1 = $" + rate.toFixed(4))
}

fetch('https://api.fixer.io/latest')
  .then((resp) => resp.json())
  .then((data) => fx.rates = data.rates)
  .then(demo)

Installation

I have included a sample Docker Compose configuration in the repo.

To build locally, type

docker-compose up -d

Now you can access the API at

http://localhost:8080

In production, create a .env file in the project root and run with

docker-compose -f docker-compose.yml -f docker-compose.prod.yml up -d

fixer's People

Contributors

0x46616c6b avatar ezkl avatar hakanensari avatar julian-zehetmayr avatar madwork avatar nilsding avatar tomtasche avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fixer's Issues

Data not present for all dates

Data for all dates is not there. When you try to pull data for 2015-01-01 it gives you data for 2014-12-31 .Similarly a lot of dates are skipped. Can this be fixed

Access-Control-Allow-Origin

Could you consider adding a Access-Control-Allow-Origin header to the response so we can call it on browser?

PKR rate is missing

Hi,
After testing this API. I found that PKR rate is missing. Since all rates are coming from database. I request you to add PKR (Pakistani Rupee) rate.
Thanks.

Rates not updated?

Hello, apparently we are retrieving data from 4 days ago (7), is that correct?

Thank you! Keep up with the great work.

Add the last updated time to the response?

I know the data updates every day at around 4PM CET. But I want to know when exactly is the data last updated. So can you make it so that there is a time in the JSON that tells when is the data last updated if the request has latest??

Money.js returning "Uncaught fx error" when changing base currency

Hi,

For some reason, money.js with the fixer.io URL "http://api.fixer.io/latest" using the code below works fine, but when I use the URL "http://api.fixer.io/latest?base=GBP" to change the base currency, it returns the error Uncaught fx error.

The JSON data returned appears to be correct, so I'm not sure what's going on - any ideas?

Thanks,

Osu

function osuConvertCurr(priceContainerParent, priceContainer, currencyContainer, activeCurrency) {
    $(priceContainerParent).each(function() {

      var priceToConvert            = $(this).find(priceContainer).data('gbp-price');
      var priceConverted            = fx.convert(priceToConvert, {from: "GBP", to: activeCurrency});
          priceConverted            = accounting.toFixed(priceConverted, 0);

      $(this).find(priceContainer).text(priceConverted + ' ');
      $(this).find(currencyContainer).text(activeCurrency);

    });
  }
$.getJSON(currenciesJSON, function(data) {
        fx.rates = data.rates;
        osuConvertCurr('.product-price', '.actual-price', '.product-currency', cc_cookie); // This function converts prices to the new currency and uses a cookie to store the preferred currency (that side of things is all working fine)
      });

Sequel::UniqueConstraintViolation: PG::UniqueViolation: ERROR: duplicate key value violates unique constraint "currencies_date_iso_code_index" DETAIL: Key (date, iso_code)=(2015-05-25, GBP) already exists.

View details in Rollbar: https://rollbar.com/hakanensari/fixer-io/items/4/


PG::UniqueViolation: ERROR:  duplicate key value violates unique constraint "currencies_date_iso_code_index"
DETAIL:  Key (date, iso_code)=(2015-05-25, GBP) already exists.

  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 180, in async_exec
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 180, in block in execute_query
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/logging.rb", line 33, in log_yield
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 180, in execute_query
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 167, in block in execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 143, in check_disconnect_errors
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 167, in execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 511, in _execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 335, in block (2 levels) in execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 532, in check_database_errors
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 335, in block in execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/connecting.rb", line 250, in block in synchronize
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/connection_pool/single.rb", line 20, in hold
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/connecting.rb", line 250, in synchronize
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 335, in execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/dataset/actions.rb", line 921, in execute
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/postgres.rb", line 655, in fetch_rows
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/dataset/actions.rb", line 804, in with_sql_each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/dataset/actions.rb", line 812, in with_sql_first
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/adapters/shared/postgres.rb", line 1349, in insert_select
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1840, in _insert_select_raw
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1813, in _insert
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1877, in block (2 levels) in _save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1124, in around_create
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1874, in block in _save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1124, in around_save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1869, in _save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1549, in block (2 levels) in save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 2032, in block in checked_transaction
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/transactions.rb", line 134, in _transaction
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/transactions.rb", line 108, in block in transaction
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/connecting.rb", line 250, in block in synchronize
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/connection_pool/single.rb", line 20, in hold
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/connecting.rb", line 250, in synchronize
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/database/transactions.rb", line 97, in transaction
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 2032, in checked_transaction
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1549, in block in save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 2020, in checked_save_failure
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 1549, in save
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 148, in create
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/sequel-4.22.0/lib/sequel/model/base.rb", line 332, in find_or_create
  File "/home/deployer/app/lib/tasks/rates.rake", line 17, in block (3 levels) in <top (required)>
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 25, in block (2 levels) in each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/nokogiri-1.6.6.2/lib/nokogiri/xml/node_set.rb", line 187, in block in each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/nokogiri-1.6.6.2/lib/nokogiri/xml/node_set.rb", line 186, in upto
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/nokogiri-1.6.6.2/lib/nokogiri/xml/node_set.rb", line 186, in each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 22, in block in each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/nokogiri-1.6.6.2/lib/nokogiri/xml/node_set.rb", line 187, in block in each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/nokogiri-1.6.6.2/lib/nokogiri/xml/node_set.rb", line 186, in upto
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/nokogiri-1.6.6.2/lib/nokogiri/xml/node_set.rb", line 186, in each
  File "/home/deployer/app/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 21, in each
  File "/home/deployer/app/lib/tasks/rates.rake", line 16, in block (2 levels) in <top (required)>
  File 

Conversion API?

First off, great project! Nice to see a fully open-source exchange rate API.

Any thoughts on exposing an API that does the actual conversion between one currency and another?

It would take in three required params:

  • amount
  • from
  • to

Optionally, it could take a date parameter which would convert at a historical rate.

Thanks!

IPv6 support

There aren't IPv6 API support for AppStore application

Exchange rates for a period of time

Hey. Is it possible to add the ability to receive exchange rates for a period of time.
For example, get the data for the last month. Not very convenient to do about 30 requests for this

XMLHttpRequest cannot load https://api.fixer.io/latest?base=USD. Invalid response. Origin 'null' is therefore not allowed access.

Hi,

I have built a webpage using angular that makes use of fixer.io data. Now it suddenly stopped working yesterday with the following error. I notice that you made some changes yesterday in the code. Is it anything you can explain, or something broke? When I download the link directly , I get a valid response (in IE, Firefox and Chrome). When I use it in some angular code, it still works in IE, but no longer in Firefox and Chrome. The below is from a session in Chrome:

XMLHttpRequest cannot load https://api.fixer.io/latest?base=USD. Invalid response. Origin 'null' is therefore not allowed access.

I am using the following angular code:

let fixerURL = "https://api.fixer.io/latest?base=USD";
$http.get(fixerURL).then(
  response => {
    $scope.fixerData = response.data;
  }, error => {
    console.log("Error retrieving data from \"" + fixerURL + "\"!\n" + JSON.stringify(error,null,2));
  }
)

The returned error object is:

{
  "data": null,
  "status": -1,
  "config": {
    "method": "GET",
    "transformRequest": [
      null
    ],
    "transformResponse": [
      null
    ],
    "url": "https://api.fixer.io/latest?base=USD",
    "headers": {
      "Accept": "application/json, text/plain, */*"
    }
  },
  "statusText": ""
}

Thanks
Jarl

Value is note accurate

I searched on google USD to INR => 67.14 INR
but as per fixer-io USD to INR => 67.004 INR

Can this will resolved????

SocketError: getaddrinfo: Name or service not known

View details in Rollbar: https://rollbar.com/hakanensari/fixer-io/items/6/


SocketError: getaddrinfo: Name or service not known
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in initialize
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in open
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in block in connect
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/timeout.rb", line 74, in timeout
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 878, in connect
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 863, in do_start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 852, in start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 583, in start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 478, in get_response
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 455, in get
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 33, in body
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 45, in xml
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 37, in namespaces
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 20, in each
  File "/home/deployer/apps/fixer/lib/tasks/rates.rake", line 16, in block (2 levels) in <top (required)>
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 240, in call
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 240, in block in execute
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 235, in each
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 235, in execute
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 179, in block in invoke_with_call_chain
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/monitor.rb", line 211, in mon_synchronize
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 172, in invoke_with_call_chain
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 165, in invoke
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 150, in invoke_task
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 106, in block (2 levels) in top_level
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 106, in each
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 106, in block in top_level
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 115, in run_with_threads
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 100, in top_level
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 78, in block in run
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 176, in standard_exception_handling
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 75, in run
  File "/usr/local/rbenv/versions/2.2.2/bin/rake", line 33, in <main>
SocketError: getaddrinfo: Name or service not known
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in initialize
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in open
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in block in connect
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/timeout.rb", line 74, in timeout
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 878, in connect
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 863, in do_start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 852, in start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 1375, in request
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar.rb", line 532, in send_payload
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar.rb", line 194, in process_payload
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar.rb", line 618, in schedule_payload
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar.rb", line 251, in report
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar.rb", line 147, in log
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar.rb", line 176, in error
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/forwardable.rb", line 183, in error
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/rollbar-1.5.3/lib/rollbar/rake.rb", line 12, in display_error_message
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 185, in rescue in standard_exception_handling
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 176, in standard_exception_handling
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 75, in run
  File "/usr/local/rbenv/versions/2.2.2/bin/rake", line 33, in <main>

SocketError: getaddrinfo: Name or service not known

View details in Rollbar: https://rollbar.com/hakanensari/fixer-io/items/5/


SocketError: getaddrinfo: Name or service not known
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in initialize
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in open
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 879, in block in connect
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/timeout.rb", line 74, in timeout
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 878, in connect
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 863, in do_start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 852, in start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 583, in start
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 478, in get_response
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/net/http.rb", line 455, in get
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 33, in body
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 45, in xml
  File "/home/deployer/apps/fixer/vendor/bundle/ruby/2.2.0/gems/fixer-0.5.0/lib/fixer/feed.rb", line 20, in each
  File "/home/deployer/apps/fixer/lib/tasks/rates.rake", line 16, in block (2 levels) in <top (required)>
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 240, in call
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 240, in block in execute
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 235, in each
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 235, in execute
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 179, in block in invoke_with_call_chain
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/monitor.rb", line 211, in mon_synchronize
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 172, in invoke_with_call_chain
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/task.rb", line 165, in invoke
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 150, in invoke_task
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 106, in block (2 levels) in top_level
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 106, in each
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 106, in block in top_level
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 115, in run_with_threads
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 100, in top_level
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 78, in block in run
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 176, in standard_exception_handling
  File "/usr/local/rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb", line 75, in run
  File "/usr/local/rbenv/versions/2.2.2/bin/rake", line 33, in <main>

HTTPS Invalid Certificate

There is an invalid TLS certificate error when calling fixer.io over HTTPS.

fixer.io uses an invalid security certificate. The certificate is only valid for the following names: *.github.com, github.com, *.github.io Error code: SSL_ERROR_BAD_CERT_DOMAIN

This issue didn't happen yesterday, so I am unsure if the site has been hacked or if a code push yesterday broke something.

Constant 502 errors?

Around 20% of calls to the API today seem to be returning a 502 error. I understand their is no guarantee of uptime with this API but thought I should make a ticket in case you were unaware.

Supported currencies

is there a proper way to get all the available currencies the API is supporting?

Taiwan Dollar

Hi,

I'm trying to make use of this for a project, but I've noticed that the API doesn't return rates for the New Taiwan Dollar (TWD).

Are there plans to include this?

Missing currencies

The following currencies are missing:

Hong Kong Dollar
Taiwan Dollar
Maccanese Pataca
Mexican peso
All South American currencies
Most East Asian currencies
All Middle Eastern currencies
Bitcoin
Russian Ruble

I personally needed the ARS, UYU and HKD, but the above list is of the ones that I found.

No Support for non SNI clients

Please can you provide support for non SNI enabled clients? Currently we are having to communicate with the API using http rather than https as our web servers don't support SNI.

Add a list of currencies that are supported?

It would be nice if you show all the supported currencies in README.md. This way I don't have to send a request every time I want to get all the currencies that are supported.

Switching to the ECB's other API

I notice a number of issues open here requesting extra exchange rates. I know the ECB feed currently being used contains a limited number of currencies - for example, it doesn't contain the Taiwan New Dollar.

However, it appears the data from the ECB is also available via their SDMX REST API. For example, you can get the USD to EUR exchange rate at the following URL:

https://sdw-wsrest.ecb.europa.eu/service/data/EXR/D.USD.EUR.SP00.A?startPeriod=2016-12-15&endPeriod=2016-12-16

The benefit of this API is much more currencies are available. For example, replace USD with TWD. Not every currency is available, but far more are available than through the current API.

Would you be willing to accept a pull request to change the API?

content type set to text/html

api.fixer.io has a Content-Type header set to text/html;charset=utf-8, even though it returns application/json. This is very problematic

Fixer.io throws 422 error code

Hi,

We are using Fixer.io and it runs great until now. We have some issues with some currency codes. The following request throws 422:
http://api.fixer.io/2016-11-17?base=AFN&symbols=RON
java.util.Currency.getInstance("AFN") recognises this code so maybe there is an issue with fixer. In browser response says "invalid base". Can you please tell what currency codes are valid for requests?

Best regards,
Tudor

P.S.: This is the first time I raise an issue on Github on other reposities, hope this is ok

C# Wrapper Created

Sorry if this is the incorrect place to put this but I created a .NET wrapper for this API.

Install via nuget

Install-Package Fixer-IO-Sharp

Github repo

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.