Giter VIP home page Giter VIP logo

exchangerate.host's Introduction

ko-fi

ExchangeRate 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.exchangerate.host.

Rates are updated around midnight UTC every working day.

Community libraries

Usage

Get the all available currencies.

GET https://api.exchangerate.host/symbols

Get the latest foreign exchange rates.

GET https://api.exchangerate.host/latest

Get historical rates for any day since 1999.

GET https://api.exchangerate.host/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 https://api.exchangerate.host/latest?base=USD

Request specific exchange rates by setting the symbols parameter.

GET https://api.exchangerate.host/latest?symbols=USD,GBP

Currency conversion endpoint, can be used to convert any amount from one currency to another.

GET https://api.exchangerate.host/convert?from=EUR&to=USD

Timeseries endpoint are for daily historical rates between two dates of your choice, with a maximum time frame of 365 days.

GET https://api.exchangerate.host/timeseries?start_date=2020-01-01&end_date=2020-04-04&symbols=EUR,USD,GBP

Using the fluctuation endpoint you will be able to retrieve information about how currencies fluctuate on a day-to-day basis.

GET https://api.exchangerate.host/fluctuation?start_date=2020-01-01&end_date=2020-04-04&symbols=EUR,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.exchangerate.host/latest')
  .then((resp) => resp.json())
  .then((data) => fx.rates = data.rates)
  .then(demo)

Backers

Thank you to all our backers! ๐Ÿ™ [Become a backer]

backers

Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [Become a sponsor]

sponsor81 sponsor0 sponsor1 sponsor2 sponsor3 sponsor4 sponsor5 sponsor6 sponsor7 sponsor8 sponsor9

exchangerate.host's People

Contributors

arzzen avatar dependabot[bot] avatar ozgurg avatar 81dr avatar philshem avatar rehhouari avatar serkanince avatar

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.