Does dhan.get_order_list() Api comes under Data API? I don’t have paid subscription for data APIs and this api is giving below error
{‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Day Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
Please let me know if I have to purchase subscription for using this api
Hello @kedar
So essentially Rate Limits on Dhan APIs are classified under three categories:
- Order APIs - Order Placement
- Non-trading APIs - Orderbook, Tradebook, Statements, Positons, etc.
- Data APIs - Historical Data
Over here, Order APIs and Non-trading APIs combined is always free for Dhan users.
All your get requests which are related to trading like orderbook, tradebook, positions, funds, etc. come under Non-trading APIs. Since you were polling dhan.get_order_list()
, you must have reached the daily rate limit here.
Rate limit details are provided in the API documentation here - DhanHQ API Rate Limit
Hi @Hardik ,
I don’t think I have crossed the rate limits… because the first call I used make every day around 9.30 was failed. Can you please check is there some other condition like monthly call limits?
Yesterday’s
2023-07-27 09:30:02,733: ############# Successfully placed SELL order ############
2023-07-27 09:30:02,733: SELL order number is : 212307274771
2023-07-27 09:30:02,742: {‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Hour Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
2023-07-27 09:30:02,742: ^^^unable to fetch order list, retrying…^^
2023-07-27 09:30:02,742: , retrying in 0.5 seconds…
2023-07-27 09:30:03,251: {‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Hour Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
2023-07-27 09:30:03,251: ^^^unable to fetch order list, retrying…^^
2023-07-27 09:30:03,251: , retrying in 0.5 seconds…
2023-07-27 09:30:03,762: {‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Hour Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
2023-07-27 09:30:03,762: ^^^unable to fetch order list, retrying…^^
=============================================================================
Day before yesterdays;
2023-07-26 09:30:02,388: ----------------order response-------------
2023-07-26 09:30:02,389: {‘status’: ‘success’, ‘remarks’: ‘’, ‘data’: {‘orderId’: ‘212307264721’, ‘orderStatus’: ‘TRANSIT’}}
2023-07-26 09:30:02,389: ----------------order response-------------
2023-07-26 09:30:02,389: ############# Successfully placed SELL order ############
2023-07-26 09:30:02,389: SELL order number is : 212307264721
2023-07-26 09:30:02,430: {‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Hour Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
2023-07-26 09:30:02,431: ^^^unable to fetch order list, retrying…^^
2023-07-26 09:30:02,431: , retrying in 0.5 seconds…
2023-07-26 09:30:02,937: {‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Hour Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
2023-07-26 09:30:02,937: ^^^unable to fetch order list, retrying…^^
2023-07-26 09:30:02,938: , retrying in 0.5 seconds…
2023-07-26 09:30:03,445: {‘status’: ‘failure’, ‘remarks’: {‘error_code’: ‘HTTP429’, ‘message’: ‘Per Hour Rate Limit Exceeded For Non Trading API’}, ‘data’: ‘’}
2023-07-26 09:30:03,445: ^^^unable to fetch order list, retrying…^^
2023-07-26 09:30:03,445: , retrying in 0.5 seconds…
============================================================
Alright @kedar
Will check logs at our backend. Can you DM me your Dhan Client ID, so that we can troubleshoot here.
Hello @kedar
We checked logs here and found that the API polling rate at your end is way higher than specified Rate Limits. You can look into Rate limits in the documentation here: Introduction - DhanHQ Ver 1.0 / API Document