Skip to main content

OHLC Quotes V3

This API retrieves Open, High, Low, Close (OHLC) quotes for one or more instruments. V3 introduces the following enhancements:

  • live_ohlc: Provides the current OHLC candle.
  • prev_ohlc: Delivers the previous minute's OHLC candle.
  • volume: Includes trading volume data.
  • ts: Returns the OHLC candle's start time.
NOTE
  • This API supports a maximum of 500 instrument keys in a single request.

Header Parameters

NameRequiredTypeDescription
AuthorizationtruestringRequires the format Bearer access_token where access_token is obtained from the Token API.
AccepttruestringDefines the content format the client expects, which should be set to application/json.

Query Parameters

NameRequiredTypeDescription
instrument_keytruestringComma separated list of instrument keys. For the regex pattern applicable to this field, see the Field Pattern Appendix.
intervaltruestringInterval to get ohlc data.
Possible values: 1d, I1, I30.
Here 1d is 1 day, I1 and I30 are 1-minute and 30-minute intervals respectively.
Responses

Response Body

{
"status": "success",
"data": {
"NSE_FO:NIFTY2543021600PE": {
"last_price": 303.9,
"instrument_token": "NSE_FO|51834",
"prev_ohlc": {
"open": 303.9,
"high": 304.3,
"low": 303.85,
"close": 304.3,
"volume": 300,
"ts": 1744019880000
},
"live_ohlc": {
"open": 304.45,
"high": 304.45,
"low": 302.75,
"close": 303.9,
"volume": 2250,
"ts": 1744019940000
}
}
}
}
NameTypeDescription
statusstringA string indicating the outcome of the request. Typically success for successful operations.
dataobjectData object holding OHLC information
data.last_pricenumberThe last traded price of symbol
data.instrument_tokenstringKey of the instrument. For the regex pattern applicable to this field, see the Field Pattern Appendix.
data.prev_ohlc.opennumberPrevious trading session open price
data.prev_ohlc.highnumberPrevious trading session high price
data.prev_ohlc.lownumberPrevious trading session low price
data.prev_ohlc.closenumberPrevious trading session close price
data.prev_ohlc.volumenumberTotal volume traded in previous trading session
data.prev_ohlc.tsnumberStart time of previous trading session
data.live_ohlc.opennumberCurrent trading session open price
data.live_ohlc.highnumberCurrent trading session high price
data.live_ohlc.lownumberCurrent trading session low price
data.live_ohlc.closenumberCurrent trading session close price
data.live_ohlc.volumenumberTotal volume traded in current trading session
data.live_ohlc.tsnumberStart time of current trading session

Note
  • For a time interval of 1d, the API returns only the live_ohlc. Previous day OHLC data is available in Historical Candle Data.

Examples

A comprehensive set of examples is provided to illustrate various use cases and implementation scenarios for this API. To view detailed examples and access sample code, please refer to: API Examples.

Loading...