coinrayjs
v1.8.18
Published
Javascript Library for Coinray.io
Downloads
45
Readme
Coinray.js - Official JavaScript client library for Coinray.io
Usage
import { Coinray } from "coinrayjs"
let coinray = new Coinray(token);
Subscribe to trades
const handle = coinray.subscribeTrades({coinraySymbol: "BINA_BTC_ETH"}, (msg) => console.log("BINA_BTC_ETH:", msg));
coinray.unsubscribeTrades({coinraySymbol: "BINA_BTC_ETH"}, handle);
Subscribe to candles
const handle = coinray.subscribeCandles({coinraySymbol: "BINA_BTC_ETH", resolution: "60"}, (msg) => console.log("BINA_BTC_ETH:", msg));
coinray.subscribeCandles({coinraySymbol: "BINA_BTC_ETH", resolution: "60"}, handle);