I tried using SL-M order using upstox api uplink for a premium of nifty 50 options , but i was unable as i got following error, but i managed to place a market order, now the issue i am facing how to set stop loss for my open position as i did not see any potential way to exit the position by using stop loss or target via upstox api. Here is the error msg generated for SL-M order. it basically says SL-M is not allowed for this script
Failed to place order. Status code: 400Error message: {“status”:“error”,“errors”:[{“errorCode”:“UDAPI100500”,“message”:“Stop-Loss Market (SL-M) orders are not allowed on this scrip.”,“propertyPath”:null,“invalidValue”:null,“error_code”:“UDAPI100500”,“property_path”:null,“invalid_value”:null}]}Order response received: <Response [400]> i am getting this order when i am trying to place order for an nifty 50 instrument
Show drafts