From cc67d4a1e2034df2fb196d2b2d3e07beed8c5224 Mon Sep 17 00:00:00 2001 From: Alex Date: Mon, 28 Apr 2025 17:49:29 +0100 Subject: [PATCH] process all request data implicitly --- application/worker.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/application/worker.py b/application/worker.py index e7ac85a9..bebd88a6 100755 --- a/application/worker.py +++ b/application/worker.py @@ -547,9 +547,7 @@ def agent_webhook_worker(self, agent_id, payload): agent_config = agents_collection.find_one({"_id": agent_oid}) if not agent_config: raise ValueError(f"Agent with ID {agent_id} not found.") - input_data = payload.get("query", "") - if input_data is None or not isinstance(input_data, str): - input_data = json.dumps(payload) + input_data = json.dumps(payload) except Exception as e: logging.error(f"Error processing agent webhook: {e}", exc_info=True) return {"status": "error", "error": str(e)}