import uvicorn

from config import api_config

from ApiServices.AuthService.create_app import create_app

# from prometheus_fastapi_instrumentator import Instrumentator


app = create_app()  # Create FastAPI application
# Instrumentator().instrument(app=app).expose(app=app)          # Setup Prometheus metrics


if __name__ == "__main__":
    # Run the application with Uvicorn Server
    uvicorn_config = uvicorn.Config(**api_config.app_as_dict)
    uvicorn.Server(uvicorn_config).run()
