cazyundee commited on
Commit
4485c4c
·
verified ·
1 Parent(s): b047b4e

Remove categories param from search route

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -349,11 +349,11 @@ def _patched_create_app(blocks, **kwargs):
349
  return JSONResponse({**API_SPECS, "runtime": _get_runtime_specs()})
350
 
351
  @fa_app.get("/respite/search")
352
- def _search(q: str = "", categories: str = "general", max_results: int = 10):
353
  if not q:
354
  return JSONResponse({"error": "Missing query parameter 'q'"}, status_code=400)
355
  try:
356
- results = _search_web(q, categories=categories, max_results=max_results)
357
  return JSONResponse(results)
358
  except Exception as e:
359
  return JSONResponse({"error": str(e)}, status_code=502)
 
349
  return JSONResponse({**API_SPECS, "runtime": _get_runtime_specs()})
350
 
351
  @fa_app.get("/respite/search")
352
+ def _search(q: str = "", max_results: int = 10):
353
  if not q:
354
  return JSONResponse({"error": "Missing query parameter 'q'"}, status_code=400)
355
  try:
356
+ results = _search_web(q, max_results=max_results)
357
  return JSONResponse(results)
358
  except Exception as e:
359
  return JSONResponse({"error": str(e)}, status_code=502)