Getting error on Order Placing ” Request method not allowed”

singhajaypratap606
Here is the Codes and below i am attaching terminal screenshot i am not able to understand where i am doing wrong
Error is —> Request method not allowed
childKiteAccess working with profile,orders,etc only error in order Placing
and i am fetching all the details from limit order json data


orderVariety = str(childKiteAccess)+"VARIETY_"+str(masterVariety).upper() # regular / amo / co / iceberg
orderExchange = str(childKiteAccess)+"EXCHANGE_"+str(masterExchange).upper() # NFO / NSE / BSE
orderTradeSymbol = str(masterTradeSymbol) # NIFTY22N1018000PE
orderTransaction_type = str(childKiteAccess)+"TRANSACTION_TYPE_"+str(masterTransaction_type).upper() # BUY / SELL
orderQuantity = int(roundDownShares) # 50
orderProduct= str(childKiteAccess)+"PRODUCT_"+str(masterProduct).upper() # CNC / NRML / MIS
orderOrderType = str(childKiteAccess)+"ORDER_TYPE_"+str(masterOrder_type).upper() # MARKET / LIMIT / SL / SL-M
orderPrice = int(masterPrice) # 60
orderValidity = str(childKiteAccess)+"VALIDITY_"+str(masterValidity).upper() # DAY / IOC / TTL
orderDisclosedQty = "None"
orderTriggerPrice = "None"
orderSquareoff = "None"
orderStoploss = "None"
orderTrailingStoploss = "None"
orderTag = "None"

print("orderVariety -> ", orderVariety)
print("orderExchange -> ", orderExchange)
print("orderTradeSymbol -> ", orderTradeSymbol)
print("orderTransaction_type -> ", orderTransaction_type)
print("orderQuantity -> ", orderQuantity)
print("orderProduct -> ", orderProduct)
print("orderOrderType -> ", orderOrderType)
print("orderPrice -> ", orderPrice)
print("orderValidity -> ", orderValidity)
print("orderDisclosedQty -> ", orderDisclosedQty)
print("orderTriggerPrice -> ", orderTriggerPrice)
print("orderSquareoff -> ", orderSquareoff)
print("orderStoploss -> ", orderStoploss)
print("orderTrailingStoploss -> ", orderTrailingStoploss)
print("orderTag -> ", orderTag)

try:
placedOrderId = childKiteAccess.place_order( variety = orderVariety, exchange = orderExchange, tradingsymbol = orderTradeSymbol, transaction_type = orderTransaction_type,
quantity = orderQuantity, product = orderProduct, order_type = orderOrderType, price=orderPrice, validity=orderValidity, disclosed_quantity=None,
trigger_price=None, squareoff=None, stoploss=None, trailing_stoploss=None, tag=None)


print("Order placed. ID is: " , placedOrderId)
except Exception as e:
print("Order placement failed: " , e)




  • sujith
    You can refer to the order placement params here.
    You might be sending upper case value for variety.
Sign In or Register to comment.