Kite connect unknown trading symbol

meena
I am unable to place an option order thro' kite connect. It fails with error "kiteconnect.exceptions.InputException: Unknown `tradingsymbol` even though the symbol is from the kite instruments. The following is the place order construct in python.
order_id = kite.place_order(variety=kite.VARIETY_AMO, tradingsymbol="HDFC21SEP2800CE".
exchange=kite.EXCHANGE_NSE,
transaction_type=kite.TRANSACTION_TYPE_BUY,
quantity=1,
order_type=kite.ORDER_TYPE_LIMIT,
price=23.8,
product=kite.PRODUCT_NRML)
I tried changing the exchange to NSE or prepend trading symbol with NFO: but still it fails. I have tried using EXCHANGE_NFO but to no avail.
  • rakeshr
    exchange=kite.EXCHANGE_NSE,
    Exchange should be NFO. You can use same instrument list to fetch exchange name as well.
  • meena
    I've already mentioned I used kite.EXCHANGE_NFO as well which resulted in the same error. Is TOTP has be enabled?
  • rakeshr
    quantity=1,
    You need to change quantity to it's lot size i.e 300 for HDFC21SEP2800CE.
  • meena
    I tried that but still the same error !
  • rakeshr
    kite.place_order( variety = kite.VARIETY_AMO,
    tradingsymbol = "HDFC21SEP2800CE",
    exchange = kite.EXCHANGE_NFO,
    transaction_type = "BUY",
    quantity = 300,
    product = kite.PRODUCT_NRML,
    order_type = kite.ORDER_TYPE_LIMIT,
    price = 23.8 )
    I just tried the above param, same as yours and it's working fine.
  • meena
    Yes, when I placed the order it worked fine. I could trace the bug to the subroutine where the exchange was hard coded as NSE though I was passing as NFO.
    Thank you !!
This discussion has been closed.