Hi Upstox Team and Community,
I’m building a trading app and would like to integrate Upstox features similar to how Sensibull does — where users can log in with their Upstox account, and then place orders directly from within my app using their own access token.
I’ve already:
- Registered my app on the Upstox developer portal
- Obtained the
client_id,client_secret, and set up aredirect_uri - Implemented OAuth login using WebView — I’m successfully receiving the authorization
code
Now I need guidance on:
- How to properly exchange the
codefor anaccess_token(andrefresh_token) securely — especially the server-side part - Best practices to store and manage user tokens (for placing orders later)
- How to place orders on behalf of the logged-in user using their token
- Any webhook/postback URL setup needed for real-time updates like order status, trades, etc.
Would really appreciate a complete flow or official guide (backend + frontend) to implement this securely and efficiently.
Thanks in advance!
Shreya