agent: look at current info, its aUEC, feat: pull up notifcations.
This commit is contained in:
@@ -42,6 +42,13 @@ class UEXClient:
|
||||
data = data[0] if data else None
|
||||
return {"status": body.get("status"), "user": data}
|
||||
|
||||
async def get_user_notifications(self) -> dict[str, Any]:
|
||||
body = await self.get("user_notifications", authenticated=True)
|
||||
data = body.get("data") or []
|
||||
if isinstance(data, dict):
|
||||
data = [data]
|
||||
return {"status": body.get("status"), "notifications": data}
|
||||
|
||||
async def post(self, path: str, payload: dict[str, Any], authenticated: bool = True) -> dict[str, Any]:
|
||||
async with httpx.AsyncClient(timeout=30) as client:
|
||||
response = await client.post(
|
||||
|
||||
Reference in New Issue
Block a user