Coverage for app/routers/auth_keycloak.py: 80.00%

5 statements  

« prev     ^ index     » next       coverage.py v7.14.1, created at 2026-07-25 15:51 +0000

1""" 

2Auth Router - Keycloak Version 

3 

4Serves the public auth health check so operators can probe the auth 

5subsystem without authenticating. "Who am I" lives at ``/users/me``. 

6""" 

7from fastapi import APIRouter 

8 

9router = APIRouter() 

10 

11 

12# ---------------------------------------------------------------- 

13# HEALTH CHECK 

14# ---------------------------------------------------------------- 

15@router.get("/health") 

16def auth_health(): 

17 """Check if auth service is healthy""" 

18 return { 

19 "status": "healthy", 

20 "auth_method": "keycloak", 

21 "message": "Authentication via Keycloak" 

22 }