INNER CODE UNIT · Python

_require_codex_runtime_api_enabled

wzn1118/AsteriaAnalyst · backend/app/main.py:150

def _require_codex_runtime_api_enabled() -> None:
    settings = load_runtime_settings()
    if settings.codex_runtime_api_enabled:
        return
    raise HTTPException(
        status_code=403,
        detail=(
            "Codex runtime API is disabled. "
            "Set ASTERIA_ENABLE_CODEX_RUNTIME_API=1 to enable /api/codex-runs and /api/codex-run-jobs."
        ),
    )


def _require_local_skill_installer_enabled() -> None:
    enabled = str(os.getenv("ASTERIA_ENABLE_LOCAL_SKILL_INSTALLER", "")).strip().lower()
    if enabled in {"1", "true", "yes", "on"}:
        return
    raise HTTPException(

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…