diff --git a/src/hubgw/api/v1/router.py b/src/hubgw/api/v1/router.py index 7fc0f08..f476e71 100644 --- a/src/hubgw/api/v1/router.py +++ b/src/hubgw/api/v1/router.py @@ -5,7 +5,7 @@ from hubgw.api.v1 import health, homes, kits, cooldowns, warps, whitelist, punis api_router = APIRouter() -# Include all sub-routers + api_router.include_router(health.router, prefix="/health", tags=["health"]) api_router.include_router(homes.router, prefix="/homes", tags=["homes"]) api_router.include_router(kits.router, prefix="/kits", tags=["kits"]) diff --git a/src/hubgw/main.py b/src/hubgw/main.py index a498e29..b5357b3 100644 --- a/src/hubgw/main.py +++ b/src/hubgw/main.py @@ -3,6 +3,7 @@ from contextlib import asynccontextmanager from fastapi import FastAPI from hubgw.core.logging import setup_logging from hubgw.context import AppContext +from hubgw.api.v1.router import api_router @asynccontextmanager @@ -23,11 +24,8 @@ def create_app() -> FastAPI: lifespan=lifespan ) - # Setup logging setup_logging() - # Include routers - from hubgw.api.v1.router import api_router app.include_router(api_router, prefix="/api/v1") return app