|
|
@@ -1,4 +1,3 @@
|
|
|
-"""FastAPI 应用入口。"""
|
|
|
from __future__ import annotations
|
|
|
|
|
|
import asyncio
|
|
|
@@ -8,11 +7,11 @@ from typing import AsyncIterator
|
|
|
|
|
|
from fastapi import FastAPI
|
|
|
|
|
|
-from app.config import settings
|
|
|
-from app.docs_auth import setup_protected_docs
|
|
|
-from app.exception_handlers import register_exception_handlers
|
|
|
-from app.openapi import setup_custom_openapi
|
|
|
-from app.response import ApiResponse
|
|
|
+from app.core.config import settings
|
|
|
+from app.core.docs_auth import setup_protected_docs
|
|
|
+from app.core.exception_handlers import register_exception_handlers
|
|
|
+from app.core.openapi import setup_custom_openapi
|
|
|
+from app.core.response import ApiResponse
|
|
|
from app.routers import search
|
|
|
from app.schemas import CacheRefreshResult, CacheStatus
|
|
|
from app.services.cache import (
|
|
|
@@ -89,7 +88,6 @@ app = FastAPI(
|
|
|
description="封装 Zendesk Help Center 搜索;FAQ",
|
|
|
version="1.0.0",
|
|
|
lifespan=lifespan,
|
|
|
- # 关闭默认 docs,由 setup_protected_docs 注册受 HTTP Basic 保护的等价路由
|
|
|
docs_url=None,
|
|
|
redoc_url=None,
|
|
|
openapi_url=None,
|