fix(billing): Remove unused client_id from agent constructors

This commit is contained in:
Chris Christiansen 2026-05-29 23:07:09 +00:00
parent 6634ee4de0
commit 07d49321a4

View File

@ -131,7 +131,7 @@ def auth_callback(code: str, state: str):
@app.get("/billing/summary") @app.get("/billing/summary")
def billing_summary(client_id: str = ""): def billing_summary(client_id: str = ""):
try: try:
return BillingAgent(client_id=client_id or None).get_summary() return BillingAgent().get_summary()
except Exception as exc: except Exception as exc:
return JSONResponse(status_code=500, content={"error": str(exc)}) return JSONResponse(status_code=500, content={"error": str(exc)})
@ -139,7 +139,7 @@ def billing_summary(client_id: str = ""):
@app.get("/billing/forecast") @app.get("/billing/forecast")
def billing_forecast(client_id: str = ""): def billing_forecast(client_id: str = ""):
try: try:
return BillingAgent(client_id=client_id or None).get_forecast() return BillingAgent().get_forecast()
except Exception as exc: except Exception as exc:
return JSONResponse(status_code=500, content={"error": str(exc)}) return JSONResponse(status_code=500, content={"error": str(exc)})
@ -147,7 +147,7 @@ def billing_forecast(client_id: str = ""):
@app.get("/billing/anomalies") @app.get("/billing/anomalies")
def billing_anomalies(client_id: str = ""): def billing_anomalies(client_id: str = ""):
try: try:
return AnomalyDetector(client_id=client_id or None).detect_anomalies() return AnomalyDetector().detect_anomalies()
except Exception as exc: except Exception as exc:
return JSONResponse(status_code=500, content={"error": str(exc)}) return JSONResponse(status_code=500, content={"error": str(exc)})