27 lines
639 B
Python
27 lines
639 B
Python
"""FastAPI app factory."""
|
|
|
|
from fastapi import FastAPI
|
|
|
|
from app import __version__
|
|
from app.routers import documents, edits, health, render
|
|
|
|
|
|
def create_app() -> FastAPI:
|
|
app = FastAPI(
|
|
title="PDF Engine Gateway",
|
|
version=__version__,
|
|
description="Auth, metadata, storage, and job-queue gateway over the C++ PDF engine.",
|
|
)
|
|
|
|
app.include_router(health.router)
|
|
app.include_router(documents.router)
|
|
app.include_router(render.router)
|
|
app.include_router(render.compat_router)
|
|
app.include_router(edits.router)
|
|
app.include_router(edits.compat_router)
|
|
|
|
return app
|
|
|
|
|
|
app = create_app()
|