"Too many requests" error while placing cancel request

pivottrading.net
pivottrading.net edited November 2016 in General
Hey,

When does the below error comes? What are the details that generate this error?
I was trying to place cancel order for some 30 orders in one shot.

I got proper cancellation response for first 16 request and then i got below error

{"status": "error", "message": "Too many requests", "error_type": "NetworkException"}

How many cancel request can be placed simultaneously ?

For my strategy, based on some condition, i need to cancel my existing open orders in market.

Thanks,
Sourabh.
  • sujith
    Hi Sourabh,
    You have hit API rate limit.
    You can only send 3 request per second.
  • pivottrading.net
    Hey dude, you should increase this. Atleast for order cancellation and order placement, please dont keep any limit.

    Vivek/Kailash, I think we should increase the limit for order cancellation.

    If i have few orders pending and my program identifies reversal, i will need to cancel those orders.

    Atleast increase the limit for cancellation to 15 request per second.

    Today as well in my live market strategy i got his error.

    Your views are appreciable.

    Thanks,
    Sourabh.
  • Vivek
    Vivek edited November 2016
    @pivottrading.net It makes sense to increase the rate limitng for order cancellation but for order place Kite connect is not meant to be used like that. Anyway we will increase rate limiting for both the api calls.
  • pivottrading.net
    @vivek Thanks Vivek. Do let know, what is the limit that you are setting, so accordingly i will make changes in my code.

    And you can always plan for scalability for such issues. In future, I will send request with much more volume and number of request :P. (Hopefully :D if my strategy works good.... ;) )
Sign In or Register to comment.