diff --git a/src/main.py b/src/main.py index 88c04f2..5754acc 100644 --- a/src/main.py +++ b/src/main.py @@ -268,6 +268,17 @@ app.include_router(sse_router) app.include_router(mail_router) app.include_router(toolchain_router) +# --------------------------------------------------------------------------- +# 健康检查端点 +# --------------------------------------------------------------------------- + + +@app.get("/api/healthz") +async def healthz(): + """轻量级健康检查,无需认证""" + return {"status": "ok"} + + # --------------------------------------------------------------------------- # 兼容端点 # ---------------------------------------------------------------------------