I wish to use Algo trading thru a 3rd party webhook.
I searched for the webhook integration on your help pages but they all talk about TV webhooks.
Can you forward me details of any independent webhook implementation? Thanks
Thank you for the feedback. We have already added sample code on GitHub and PyPi. Also, we are looking into adding detailed Python Client documentation soon as well.
How do we fetch the CMP / LTP of any scrip, So that i can dynamically take SL / TGT and SquareOff my options position. I am trying to do this programattically because, there is no OCO (only for intraday) now on API.
Hello @Mohan
First of all, welcome to Dhan Community. To answer your question, Security ID is an exchange level standard and all our systems are built on the same. However, we have duly noted and will evaluate this.
@Mohan You can create different types of order at your end using custom scrips and Dhan APIs. For SL/TGT to square off positions, you can place SL order/ Limit order respectively.
Hi,
Thanks for providing the API’s, I want to develop my own strategy in .net/ powershell using the API’s. I have a question on how to test the code which I am writing? Is there any access token for testing the features? The access token which I tried points to the live environment.
Welcome to Dhan Community! It’s awesome to know that you are looking to build on Dhan APIs.
Currently, we do not provide any sandbox for API testing. However, our users do test these APIs on live environment either by placing after market orders or limit orders and later cancelling them from frontend.
Hope this helps! Feel free to reach out to @Dhan_Help if you face any issues while integrating.
Can you please provide sample request which works for Bracket Order. I am trying with below request but getting 400 bad request everytime. Also if I set afterMarketOrder to true and amoTime to ‘OPEN’, then that request should work even when market is closed?
In the request structure, fields “boStopLossValue” and “boProfitValue” represent change in price between Stop Loss/Target and order price. So, you only need to enter the price difference there. The same is mentioned in the documentation.
Also, in the “disclosedQuantity” field, you can enter 0 if you want to disclose all of the order quantity. On an exchange level, Disclosed Quantity needs to be more than 10% and less than 30% of the actual order quantity.