From 1c740053763f771b2045f9b2ac64132d2d63a75b Mon Sep 17 00:00:00 2001 From: MuslemRahimi Date: Sat, 28 Dec 2024 16:46:11 +0100 Subject: [PATCH] update endpoint --- app/main.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/main.py b/app/main.py index 10bb138..12a7da5 100755 --- a/app/main.py +++ b/app/main.py @@ -4221,9 +4221,9 @@ async def get_statistics(data: TickerData, api_key: str = Security(get_api_key)) headers={"Content-Encoding": "gzip"} ) -@app.get("/sector-flow") -async def get_sector_flow(api_key: str = Security(get_api_key)): - cache_key = f"sector-flow" +@app.get("/market-flow") +async def get_market_flow(api_key: str = Security(get_api_key)): + cache_key = f"market-flow" cached_result = redis_client.get(cache_key) if cached_result: return StreamingResponse( @@ -4233,7 +4233,7 @@ async def get_sector_flow(api_key: str = Security(get_api_key)): ) try: - with open(f"json/sector-flow/data.json", 'rb') as file: + with open(f"json/market-flow/data.json", 'rb') as file: res = orjson.loads(file.read()) except: res = {}