Download app/integrations/core.py from Modulo-6/api: direct link, hf CLI and curl.
- Browser
- Download file 449 Bytes
-
https://huggingface.co/spaces/Modulo-6/api/resolve/31c8dd67e47a516206b4122c4da00a634486a247/app/integrations/core.py
- Command line
-
hf download hf://spaces/Modulo-6/api@31c8dd67e47a516206b4122c4da00a634486a247/app/integrations/core.py
-
curl -L -o core.py https://huggingface.co/spaces/Modulo-6/api/resolve/31c8dd67e47a516206b4122c4da00a634486a247/app/integrations/core.py
449 Bytes
| """ | |
| M10 Core — validación de pacientes. | |
| """ | |
| from app.config import settings | |
| from app.integrations._base import _get | |
| def validate_patient(paciente_id: int) -> dict | None: | |
| """Verifica existencia del paciente en M10. Retorna datos básicos o None.""" | |
| if settings.mock_external_services: | |
| return {"id": paciente_id, "nombre": "Paciente", "apellido": "Mock"} | |
| return _get(f"{settings.m10_core_url}/api/v1/usuarios/{paciente_id}") | |