Fetch market data from cryptocurrency exchanges
JavaScript
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
lib
test
.gitignore
.travis.yml
LICENSE
README.md
index.js
package.json

README.md

cryptofetch

Fetch market data from cryptocurrency exchanges

Build Status

Install

npm install cryptofetch

Usage

Function takes three arguments: exchange, currency and base. Returns a promise that resolves to an object with several properties related to the exchange and normalized where possible. Current exchanges and data available are listed below.

var fetch = require('cryptofetch');

// Query the current data for LTC in terms of LTC/BTC on BTC-e
fetch('btc-e', 'ltc', 'btc').then(function (data) {
  console.log(data);
  /*
  {
    high: 0.03889,
    low: 0.0301,
    avg: 0.034495,
    vol: 22371.85528,
    last: 0.03626,
    buy: 0.03626,
    sell: 0.03611
  }
  */
});

Current Exchanges

Currently supported exchanges and the data returned. More exchanges can be added via ./lib/exchanges/.

  • btc-e: high, low, avg, vol, last, buy, sell
  • vircurex: high, low, last
  • bter: high, low, avg, last, buy, sell