trygithubactions / api /routers /show_analytics.py
subashpoudel's picture
Code refactoring
38cf703
raw
history blame
337 Bytes
from fastapi import APIRouter
from api.stored_data import stored_data
from src.genai.orchestration_agent.utils.utils import AnalyticsViewer
router=APIRouter()
@router.post("/show-analytics")
def show_analytics_endpoint():
response = AnalyticsViewer(stored_data['business_details']).show_analytics()
return {'response': response}