Added time() and useServerTime options
- You can now use the
useServerTime
option to synchronize with the servers time at startup - You can now pass a callback function to options() which runs after the synchronization is complete
binance.options({
APIKEY: '<key>',
APISECRET: '<secret>',
useServerTime: true
}, main);
function main() {
binance.balance((error, balances) => {
if ( error ) {
console.error(error);
return;
}
console.log("balances()", balances);
console.log("BNB balance: ", balances.BNB.available);
});
}