Skip to content

Time Price Series

The Get Time Price Data APIs enable you to get chart data for analysis.

POST: /api/timePriceSeries

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

Request Details

Parameter Description
userId Logged in User Id
exchange Exchange
token Trading Symbol Token
starttime Start time (use 24hr Date time)
dd/mm/yyyy HH:mm:ss
endtime End Time (use 24hr Date time)
dd/mm/yyyy HH:mm:ss
jKey Key Obtained on login success.

Code

from thefirstock import thefirstock 

TPS = thefirstock.firstock_TimePriceSeries(
exchange="NSE",
token="22",
endTime="",
startTime=""
)
  curl -X POST 'https://connect.thefirstock.com/api/timePriceSeries' \
  -H 'Content-Type: application/json' \
  -d '{
    "userId": "",
    "exchange": "",
    "token": "",
    "endtime": "",
    "starttime": "",
    "jKey": ""
    }'
const Firstock = require('thefirstock');

const firstock = new Firstock();

firstock.timePriceSeries({
exchange: "",
token: "",
endTime: "",
startTime: "",
intrv:""
}, (err, result) => {
console.log("Error, ", err)
console.log("Result: ", result)
})
using thefirstock;

class Program
{
public static void Main()
{
    Firstock firstock = new Firstock(); 
    var result = firstock.timePriceSeries(
        exchange: "NSE",
        token: "22",
        endTime: "02/08/2022 15:30:08",
        startTime: "05/07/2022 10:30:08",
        intrv:"3"
      );
}
}

Response Details

Response data will be in json format in case for failure:

Parameter Description
stat Ok or Not_Ok
TPData failure indication.
emsg This will be present only in case of errors.

Response data will be in json format in case of Success:

Parameter Description
stat Ok or Not_Ok
TPData success indication.
emsg DD/MM/CCYY hh:mm:ss
into Interval open
inth Interval high
intl Interval low
intc Interval close
intvwrap Interval vwrap
intvwrap Interval vwrap
intv Interval volume
v volume
intooi Interval io change
oi oi
ssboi

Sample Response

[
{
"stat": "Ok",
"time": "31-05-2022 15:30:08",
"ssboe": "1653991208",
"into": "810.85",
"inth": "810.85",
"intl": "810.85",
"intc": "810.85",
"intvwap": "0.00",
"intv": "0",
"intoi": "0",
"v": "4362496",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:29:00",
"ssboe": "1653991140",
"into": "810.20",
"inth": "810.95",
"intl": "810.10",
"intc": "810.90",
"intvwap": "810.14",
"intv": "37518",
"intoi": "0",
"v": "4362496",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:28:00",
"ssboe": "1653991080",
"into": "810.35",
"inth": "810.50",
"intl": "810.25",
"intc": "810.50",
"intvwap": "809.92",
"intv": "21396",
"intoi": "0",
"v": "4324978",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:27:00",
"ssboe": "1653991020",
"into": "810.45",
"inth": "810.50",
"intl": "810.00",
"intc": "810.40",
"intvwap": "810.25",
"intv": "14953",
"intoi": "0",
"v": "4303582",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:26:00",
"ssboe": "1653990960",
"into": "810.40",
"inth": "810.45",
"intl": "810.10",
"intc": "810.40",
"intvwap": "809.89",
"intv": "20943",
"intoi": "0",
"v": "4288629",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:25:00",
"ssboe": "1653990900",
"into": "810.00",
"inth": "810.90",
"intl": "810.00",
"intc": "810.45",
"intvwap": "810.09",
"intv": "77565",
"intoi": "0",
"v": "4267686",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:24:00",
"ssboe": "1653990840",
"into": "811.25",
"inth": "811.30",
"intl": "810.10",
"intc": "810.80",
"intvwap": "810.37",
"intv": "78348",
"intoi": "0",
"v": "4190121",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:23:00",
"ssboe": "1653990780",
"into": "811.25",
"inth": "811.30",
"intl": "810.60",
"intc": "811.00",
"intvwap": "811.98",
"intv": "19128",
"intoi": "0",
"v": "4111773",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:22:00",
"ssboe": "1653990720",
"into": "811.50",
"inth": "811.55",
"intl": "810.55",
"intc": "811.35",
"intvwap": "810.35",
"intv": "20601",
"intoi": "0",
"v": "4092645",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:21:00",
"ssboe": "1653990660",
"into": "810.75",
"inth": "812.00",
"intl": "810.35",
"intc": "811.15",
"intvwap": "811.37",
"intv": "24588",
"intoi": "0",
"v": "4072044",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:20:00",
"ssboe": "1653990600",
"into": "811.05",
"inth": "812.00",
"intl": "810.75",
"intc": "810.95",
"intvwap": "811.12",
"intv": "61112",
"intoi": "0",
"v": "4047456",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:19:00",
"ssboe": "1653990540",
"into": "811.30",
"inth": "811.50",
"intl": "811.00",
"intc": "811.45",
"intvwap": "811.16",
"intv": "45030",
"intoi": "0",
"v": "3986344",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:18:00",
"ssboe": "1653990480",
"into": "811.35",
"inth": "811.65",
"intl": "811.00",
"intc": "811.00",
"intvwap": "810.76",
"intv": "13741",
"intoi": "0",
"v": "3941314",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:17:00",
"ssboe": "1653990420",
"into": "811.75",
"inth": "811.75",
"intl": "811.15",
"intc": "811.65",
"intvwap": "810.62",
"intv": "13323",
"intoi": "0",
"v": "3927573",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:16:00",
"ssboe": "1653990360",
"into": "811.65",
"inth": "812.00",
"intl": "811.00",
"intc": "811.55",
"intvwap": "811.76",
"intv": "40768",
"intoi": "0",
"v": "3914250",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:15:00",
"ssboe": "1653990300",
"into": "812.10",
"inth": "812.10",
"intl": "811.65",
"intc": "811.95",
"intvwap": "810.72",
"intv": "13198",
"intoi": "0",
"v": "3873482",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:14:00",
"ssboe": "1653990240",
"into": "812.80",
"inth": "812.80",
"intl": "812.00",
"intc": "812.00",
"intvwap": "813.41",
"intv": "24186",
"intoi": "0",
"v": "3860284",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:13:00",
"ssboe": "1653990180",
"into": "812.80",
"inth": "812.85",
"intl": "812.55",
"intc": "812.85",
"intvwap": "812.41",
"intv": "9117",
"intoi": "0",
"v": "3836098",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:12:00",
"ssboe": "1653990120",
"into": "812.30",
"inth": "812.85",
"intl": "812.30",
"intc": "812.60",
"intvwap": "812.44",
"intv": "9149",
"intoi": "0",
"v": "3826981",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:11:00",
"ssboe": "1653990060",
"into": "812.40",
"inth": "812.90",
"intl": "812.30",
"intc": "812.40",
"intvwap": "812.42",
"intv": "18088",
"intoi": "0",
"v": "3817832",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:10:00",
"ssboe": "1653990000",
"into": "812.20",
"inth": "812.65",
"intl": "812.05",
"intc": "812.30",
"intvwap": "810.04",
"intv": "11471",
"intoi": "0",
"v": "3799744",
"oi": "0"
},
{
"stat": "Ok",
"time": "31-05-2022 15:09:00",
"ssboe": "1653989940",
"into": "811.80",
"inth": "812.75",
"intl": "811.60",
"intc": "812.35",
"intvwap": "812.77",
"intv": "28953",
"intoi": "0",
"v": "3788273",
"oi": "0"
}
]  
[
{
"stat": "Not_Ok",
"emsg": "Invalid Session Key"
}
]