It looks like you're new here. If you want to get involved, click one of these buttons!
<form method="post" id="basket-form" action="https://kite.trade/connect/basket">
<input type="hidden" name="api_key" value="4slvsk0ov1w0zgvk" />
<input type="hidden" id="basket" name="data" value="" />
</form>
<script>
console.log("i was called");
function send(){
var your_basket=[{
"tradingsymbol": "INFY",
"exchange": "NSE",
"transaction_type": "BUY",
"order_type": "MARKET",
"quantity": 10
}, {
"tradingsymbol": "NIFTY15DECFUT",
"exchange": "NFO",
"transaction_type": "SELL",
"order_type": "LIMIT",
"price": 7845,
"quantity": 1
}];
document.getElementById("basket").value =JSON.stringify(your_basket);
document.getElementById("basket-form").submit();
};
</script>
I have a single page app , now i will embed the kite button in my page and after that user will click on it and will be taken to kite login page where he will enter his details and place trades . After completion of trade my redirect url will be called ..... now from here what do i need to do to get the token.