README
Binance
A library to work with Binance API, written in typescript. Forked from Zoey Garveys's binance (zoeyg/binance) js library.
Example
import BinanceRest, { BinanceWS, ConfigInterface } from "./index";
(async () => {
const config: ConfigInterface = {
key: '<your key goes here>',
secret: '<your secret goes here>',
};
const rest = new BinanceRest(config);
await rest.ticker24hr({ symbol: 'BTCUSDT' });
const bws = new BinanceWS();
bws.onTicker('BTCUSDT', (data) => {
console.log(data);
});
})();