"""Public app metadata (display name + version) for the frontend brand layer, plus the phase-59 docs-push flag (the "Save as doc" gating).""" from __future__ import annotations from fastapi import APIRouter, Depends from app.config import Settings, get_settings router = APIRouter(tags=["config"]) @router.get("/config") def app_config(settings: Settings = Depends(get_settings)) -> dict[str, str | bool]: # noqa: B008 """Public app metadata for the frontend brand layer (phase 39) + the phase-59 ``docs_repo_configured`` flag — the chat page's "Save as doc" button gating, surfaced the way ``app_name`` is (the SAME boot fetch, no new network surface). Inert false while ``BOR_DOCS_REPO`` is empty (the feature is off, D3).""" return { "app_name": settings.app_name, "version": settings.app_version, "docs_repo_configured": settings.docs_configured, }