Hi, I want to place BO after the order completion of already placed BO. I have to code at the Post Back page for this. Any one please guide me how to know the particular order is completed. Please guide me how can I code accordingly.
@sujith Yes, now I can successfully get the response on the postback page. Now, I want to post an BO at the same time.
But, for the placing of an order, Request Token is necessary to get and set the access token. How can I get this request token and generate the access token to place an order at the post back page?
@sachinstlko09 You need to store the generated the access token and retrieve it on the post-back page. A simple example would be; Just write the access token to text file, say my_token.txt on successful login and retrieve the access token in the post back page by just reading the text file my_token.txt and place orders as per your logic.
You can check
status
in the postback response. Order status will be 'COMPLETE'. You can use that as an event for placing a new order.But, for the placing of an order, Request Token is necessary to get and set the access token. How can I get this request token and generate the access token to place an order at the post back page?
I think you can post an event to your program and place orders from there.
Please confirm.
As per my current analysis, Request Token we can get only at the Redirect URL page of the app.
Yes, you get request token only in redirect url page. It is difficult to comment unless one knows complete setup and code.
https://kite.trade/docs/connect/v1/#postback-webhooks
When I have used this , it throws "Invalid session" issue.
Kite Connect authenticates all API calls with the access token. You need to pass access token. Kite Connect won't recognize checksum.
You need to store the generated the access token and retrieve it on the post-back page.
A simple example would be;
Just write the access token to text file, say my_token.txt on successful login and
retrieve the access token in the post back page by just reading the text file my_token.txt
and place orders as per your logic.
Hi, I understood your suggestion. But, Can we use same access token multiple times to place an order.
Please confirm !