Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
@@ -69,7 +69,7 @@ async def get_stocks_data(ticker: str = Query(..., description="Enter your stock
|
|
69 |
|
70 |
# Fetch Stock Chain
|
71 |
@app.get('/chain', response_model=CHAIN, responses={200: {"description": "Successful response", "content": {"application/json": {"example": chain_response_example}}}})
|
72 |
-
async def get_chain(ticker: str = Query(..., description="Enter your index name from [nifty, banknifty]", example='
|
73 |
try:
|
74 |
response, exp, index_ltp = fetcher.fetch_option_chain(ticker)
|
75 |
response = response.to_dict(orient="records")
|
|
|
69 |
|
70 |
# Fetch Stock Chain
|
71 |
@app.get('/chain', response_model=CHAIN, responses={200: {"description": "Successful response", "content": {"application/json": {"example": chain_response_example}}}})
|
72 |
+
async def get_chain(ticker: str = Query(..., description="Enter your index name from [nifty, banknifty]", example='banknifty')):
|
73 |
try:
|
74 |
response, exp, index_ltp = fetcher.fetch_option_chain(ticker)
|
75 |
response = response.to_dict(orient="records")
|