nsepython 2.7__tar.gz → 2.8__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: nsepython
3
- Version: 2.7
3
+ Version: 2.8
4
4
  Summary: Python library for NSE India APIs
5
5
  Home-page: https://github.com/aeron7/nsepython
6
6
  Author: Aeron7
@@ -628,6 +628,7 @@ def derivative_history_virgin(symbol,start_date,end_date,instrumentType,expiry_d
628
628
  logging.info(nsefetch_url)
629
629
  logging.info(payload)
630
630
  return pd.DataFrame.from_records(payload["data"])
631
+
631
632
  def derivative_history(symbol,start_date,end_date,instrumentType,expiry_date,strikePrice="",optionType=""):
632
633
  #We are getting the input in text. So it is being converted to Datetime object from String.
633
634
  start_date = datetime.datetime.strptime(start_date, "%d-%m-%Y")
@@ -925,4 +926,10 @@ def nse_expirydetails_by_symbol(symbol,meta ="Futures",i=0):
925
926
  currentExpiry=expiry_dates[i]
926
927
  currentExpiry = datetime.datetime.strptime(currentExpiry,'%d-%b-%Y').date()
927
928
  dte = (currentExpiry - datetime.datetime.now().date()).days
928
- return currentExpiry,dte
929
+ return currentExpiry,dte
930
+
931
+ def security_wise_archive(from_date, to_date, symbol, series="ALL"):
932
+ base_url = "https://www.nseindia.com/api/historical/securityArchives"
933
+ url = f"{base_url}?from={from_date}&to={to_date}&symbol={symbol.upper()}&dataType=priceVolumeDeliverable&series={series.upper()}"
934
+ payload = nsefetch(url)
935
+ return pd.DataFrame(payload['data'])
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: nsepython
3
- Version: 2.7
3
+ Version: 2.8
4
4
  Summary: Python library for NSE India APIs
5
5
  Home-page: https://github.com/aeron7/nsepython
6
6
  Author: Aeron7
@@ -6,7 +6,7 @@ with open("README.md", "r") as fh:
6
6
  setuptools.setup(
7
7
  name = 'nsepython',
8
8
  packages=setuptools.find_packages(),
9
- version = '2.7',
9
+ version = '2.8',
10
10
  include_package_data=True,
11
11
  description = 'Python library for NSE India APIs',
12
12
  long_description=long_description,
File without changes
File without changes
File without changes
File without changes