It looks like you're new here. If you want to get involved, click one of these buttons!
function ZerodhaPlaceOrder(OrderFutures) {
var transaction_type = ''
if (OrderFutures > 0) {
transaction_type = "BUY"
}
if (OrderFutures < 0) {
transaction_type = "SELL"
}
var PlaceOrder = Math.abs(OrderFutures)
return new Promise((resolve, reject) => {
kc.placeOrder("regular", {
"exchange": "NSE_FO",
"tradingsymbol": "NIFTY19JUNFUT",
"transaction_type": transaction_type,
"quantity": PlaceOrder,
"product": "NRML",
"order_type": "MARKET"
}).then(async function (response) {
console.log(response);
order_id = response.data.order_id;
const1 = await ZerodhaGetOrderStatus(order_id);
resolve(response);
})
.catch(function (error) {
IsEnteredDecision = 0;
console.log(error);
reject(error);
});
});
}
Exchange should be NFO.Check complete order params here.