btcxr

0.0.6 • Public • Published

btcxr Build Status

NPM

btcxr is a wrapper around the Blockchain api ticker method

Installing globally as binary

$ npm install btcxr -g

Usage as binary

bitcoin JPY
//=> JPY: ¥28930.17

Installing as module

$ npm install --save btcxr

Usage as module

var btcxr = require('btcxr');
 
function bitcoinCallback(bitcoin){
  console.log('GBP: ' + bitcoin.symbol + bitcoin.last);
}
 
btcxr("GBP", bitcoinCallback);

API

btcxr(currency, callback)

currency

Required
Type: string

Possible values: USD,ISK,HKD,TWD,CHF,EUR,DKK,CLP,CAD,CNY,THB,AUD,SGD,KRW,JPY,PLN,GBP,SEK,NZD,BRL,RUB

Defaults to: USD

callback(bitcoin)

Type: function

bitcoin properties:

  • 15m
  • last
  • buy
  • sell
  • symbol

License

MIT © afj176

Package Sidebar

Install

npm i btcxr

Weekly Downloads

4

Version

0.0.6

License

MIT

Last publish

Collaborators

  • afj176