Query Regarding "Order ID" and "Unique Order ID" in Smart API
-
Query:
If I place a buy order first and, after some time, a sell order to square off the trade:What will remain the same between the following: (A) Buy order (B) Sell order (C) GetTradeBook (D) GetOrderBook
Specifically, will the "Order ID" and "Unique Order ID" be the same in these cases?
Each order provides both "Order ID" and "Unique Order ID." My concern is to confirm whether the square-off trade was successfully executed. Although I can refer to the TradeBook to check Trade Executed, there may be multiple Trade Executed in the day for the same token ID, making it unclear.
-
@A56409402 the quantity of buy and sell should match to ensure you have successfully squared off.
case 1: you buy infy, 10 qty for intraday and then buy infy 5 qty for intraday again. It would be added to the same position. So while squaring off, you need to square off 15 qty of intraday.
case 2: you buy infy 10 qty for intraday and infy 10 qty for delivery, you would need to place 2 sell orders of 10 qty each for intraday and delivery.
You can verify the same after squaring off buy using GetTradeBook