Unable to place order for certain scrips

swas99
Hi,

I am getting an InputException when placing buy orders for ['SUBEX', 'TATASTEELPP'] (both BSE).
Error:
Unknown `tradingsymbol`.
com.zerodhatech.kiteconnect.kitehttp.exceptions.InputException
Buy/Sell for `TATASTLPP-E1` (NSE) is working fine.

I have seen this error for few other scrips as well. Is this intentional?
  • sujith
    Can you send the complete stacktrace with debug logs?
  • swas99
    That's all the message returned by KiteClient.
    e.message =
    "Unknown `tradingsymbol`."
    e.printStackTrace() =
    com.zerodhatech.kiteconnect.kitehttp.exceptions.InputException
    at com.zerodhatech.kiteconnect.kitehttp.KiteResponseHandler.dealWithException(KiteResponseHandler.java:54)
    at com.zerodhatech.kiteconnect.kitehttp.KiteResponseHandler.handle(KiteResponseHandler.java:20)
    at com.zerodhatech.kiteconnect.kitehttp.KiteRequestHandler.postRequest(KiteRequestHandler.java:85)
    at com.zerodhatech.kiteconnect.KiteConnect.placeOrder(KiteConnect.java:282)
    I can log e.code next time.
  • sujith
    You need to enable debug logs and check what are the params you are sending.
    You can check out the example here.
  • swas99
    I have the params sent to kite:
    Rejected KiteOrder:
    orderType: BUY
    symbol: UDAICEMENT
    priceE2: 2494
    dPrice: 24.95
    quantity: 401
    ERROR: Unknown `tradingsymbol`.
    KiteErrorCode: 400
    ___________________________________________________________
    orderParams.orderType = Constants.ORDER_TYPE_LIMIT;
    orderParams.tradingsymbol = symbol.trim();
    orderParams.product = Constants.PRODUCT_CNC;
    orderParams.exchange = Constants.EXCHANGE_NSE;
    orderParams.transactionType = orderType.trim();
    orderParams.validity = Constants.VALIDITY_DAY;
    orderParams.price = dPrice;
    orderParams.tag = tag;
    Order order = kiteConnect.placeOrder(orderParams, Constants.VARIETY_REGULAR);
  • swas99
    Never-mind, found the issue.

    I was hard-coding `orderParams.exchange = Constants.EXCHANGE_NSE;` while placing the order, whereas using kite's `instrument_id` at other places.

    Thanks anyway.
This discussion has been closed.