Files
xiaoxia-saas/apps/api/app/api/routes/__init__.py
T
2026-06-21 00:37:42 +08:00

18 lines
553 B
Python

"""API route package.
The canonical aggregated router lives in `app.api.router`. This package must not
import route modules at package-import time, otherwise importing any sub-route can
trigger circular imports and optional infrastructure dependencies.
"""
def __getattr__(name: str):
if name in {"api_router", "health_router"}:
from app.api.router import api_router, health_router
return {"api_router": api_router, "health_router": health_router}[name]
raise AttributeError(name)
__all__ = ["api_router", "health_router"]