Добавлен эндпоинт getELNs

This commit is contained in:
2025-09-30 11:18:14 +03:00
parent 6bc0cf98a3
commit ce36e07266
3 changed files with 74 additions and 5 deletions

View File

@ -165,3 +165,13 @@ class VITACORE_API(AsyncClient):
case _:
self.logger.error(req.json())
raise e.UnknownException
async def getELNs(self, patId: str):
req = await self.get('/getELNs', params={'patId': patId})
match req.status_code:
case st.HTTP_200_OK:
return s.ELNsModel.model_validate(req.json())
case _:
self.logger.error(req.json())
raise e.UnknownException