Skip to content

Get Started

Firstock API are a set of REST APIs that extends the usage capabilities to build a stock market investment and trading platform. It provides all the necessary functionality from real time order execution, portfolio management, live market stream nad many more.

All inputs are form-encoded parameters and responses are JSON. Standard HTTP codes are used to indicate success and error states with accompanying JSON data. The API endpoints are not cross site request enabled, hence cannot be called directly from browsers.

An API key is a key allocated to the Firstock User after opening Trading Account, users can acquire the API key by logging to https://connect.thefirstock.com/login

Note

  1. API_key: is a key allocated to the User. Input will be in string format.
  2. API_secret: ID received as response from Login 2FA.Input will be in string format..
  3. Data: is a JSON object which is referred as Input in rest description table. If there is no input mentioned in the table you need to send it as a blank object or a blank string. Input will be in string format.
pip install thefirstock
npm install thefirstock
dotnet add package thefirstock  

API URL

https://connect.thefirstock.com/api/

Websocket URL

wss://norenapi.thefirstock.com/NorenWSTP/

All APIs are considered as the POST method. All the input, as well as output data type, will be in string format unless it’s mentioned in the rest explanation section.

Exchanges Products Price Types Transaction Types
BSE - BSE Equity C - Cash & Carry for equity MKT - Market Order B - Buy
NSE - NSE Equity I - Intraday LMT - Limit Order S - Sell
NSE - NSE Equity I - Intraday LMT - Limit Order
NFO - NSE Future and Options M – Regular SL-LMT - Stop Loss Limit Order
SL-MKT - Stop Loss Market Order