Descripcion
npm install api-poloniex --save
Public api usage
const api = require('api-poloniex')();
api.public.returnTicker().then((ticker)=>{
console.log(ticker.BTC_LTC);
}).catch((err)=>{
console.log(err);
});
Push api usage
const api = require('api-poloniex')();
api.public.returnTicker().then((ticker)=>{
console.log(ticker.BTC_LTC);
}).catch((err)=>{
console.log(err);
});
Trading api usage
const apiKey = 'apiKey...........';
const secret = 'secret..................................';
const api = require('api-poloniex')(apiKey, secret);
api.trading.returnBalances().then((balances) => {
console.log(balances.BTC);
})