INNER CODE UNIT · Python
create_voyager
KLR-Pattern/fastapi-voyager · src/fastapi_voyager/server.py:110
def create_voyager(
target_app: Any,
module_color: dict[str, str] | None = None,
gzip_minimum_size: int | None = 500,
module_prefix: str | None = None,
swagger_url: str | None = None,
online_repo_url: str | None = None,
initial_page_policy: INITIAL_PAGE_POLICY = "first",
ga_id: str | None = None,
er_diagram: ErDiagram | None = None,
enable_pydantic_resolve_meta: bool = False,
server_mode: bool = False,
) -> Any:
"""
Create a voyager UI application for the given target app.
This function automatically detects the framework type (FastAPI, Django Ninja, or Litestar)
and returns an appropriately configured voyager UI application.