From 817fb134060c5124d394e0ff3d521e0942fe7921 Mon Sep 17 00:00:00 2001 From: Jeremy Cloarec Date: Fri, 3 Oct 2025 15:47:54 +0200 Subject: [PATCH] [client] add isWorkAlive query --- pycti/api/opencti_api_work.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pycti/api/opencti_api_work.py b/pycti/api/opencti_api_work.py index d9f9b9e6f..dd2307424 100644 --- a/pycti/api/opencti_api_work.py +++ b/pycti/api/opencti_api_work.py @@ -204,6 +204,15 @@ def get_work(self, work_id: str) -> Dict: result = self.api.query(query, {"id": work_id}, True) return result["data"]["work"] + def get_is_work_alive(self, work_id: str) -> Dict: + query = """ + query WorkAliveQuery($id: ID!) { + isWorkAlive(id: $id) + } + """ + result = self.api.query(query, {"id": work_id}, True) + return result["data"]["isWorkAlive"] + def get_connector_works(self, connector_id: str) -> List[Dict]: query = """ query ConnectorWorksQuery(