add health endpoint for gateway and everos

This commit is contained in:
2026-06-11 10:52:13 +08:00
parent b74923e435
commit 7155704b73
4 changed files with 138 additions and 9 deletions

View File

@ -31,6 +31,15 @@ class EverOSClient:
async def search_memory(self, payload: dict[str, Any]) -> dict[str, Any]:
return await self._post("/api/v1/memory/search", payload)
async def health_check(self) -> dict[str, Any]:
async with httpx.AsyncClient(
base_url=self.base_url,
timeout=self.timeout,
) as client:
response = await client.get("/health")
response.raise_for_status()
return response.json()
async def _post(self, path: str, payload: dict[str, Any]) -> dict[str, Any]:
async with httpx.AsyncClient(
base_url=self.base_url,