Skip to main content

Put/Call Option Chain

API to retrieve put/call option chain for an underlying symbol for a specific expiry date. The Put/Call Option chain is currently not available for the MCX Exchange.

Request

curl --location 'https://api.upstox.com/v2/option/chain?instrument_key=NSE_INDEX%7CNifty%2050&expiry_date=2024-03-28' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {your_access_token}'

Additional samples in various languages are available in the Sample Code section on this page.

Query Parameters

NameRequiredTypeDescription
instrument_keytruestringKey of an underlying symbol. For the regex pattern applicable to this field, see the Field Pattern Appendix.
expiry_datetruestringExpiry date in format: YYYY-MM-DD.

Sample Code

Get put/call option chain

import requests

url = 'https://api.upstox.com/v2/option/chain'
params = {
'instrument_key': 'NSE_INDEX|Nifty 50',
'expiry_date': '2024-03-28'
}
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'Authorization': 'Bearer {your_access_token}'
}

response = requests.get(url, params=params, headers=headers)

print(response.json())
Loading...