Skip to content
This repository was archived by the owner on Oct 30, 2023. It is now read-only.

Commit b019523

Browse files
author
Jon Eyrick
authored
Expose order() function to public API (Thanks ManuCart)
2 parents fc790e0 + 20d8004 commit b019523

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

node-binance-api.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1021,6 +1021,21 @@ let api = function Binance() {
10211021
return this;
10221022
},
10231023

1024+
1025+
/**
1026+
* Creates an order
1027+
* @param {string} side - BUY or SELL
1028+
* @param {string} symbol - the symbol to buy
1029+
* @param {numeric} quantity - the quanitity required
1030+
* @param {numeric} price - the price to pay for each unit
1031+
* @param {object} flags - addtional buy order flags
1032+
* @param {function} callback - the callback function
1033+
* @return {undefined}
1034+
*/
1035+
order: function(side, symbol, quantity, price, flags = {}, callback = false) {
1036+
order(side, symbol, quantity, price, flags, callback);
1037+
}
1038+
10241039
/**
10251040
* Creates a buy order
10261041
* @param {string} symbol - the symbol to buy

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "node-binance-api",
3-
"version": "0.7.2",
3+
"version": "0.7.3",
44
"description": "Binance API for node https://github.com/jaggedsoft/node-binance-api",
55
"main": "node-binance-api.js",
66
"dependencies": {

0 commit comments

Comments
 (0)