feat: 添加通用配置分享相关接口

This commit is contained in:
DLmaster361
2025-08-17 23:41:21 +08:00
parent 515367f61f
commit 998aaffd70
4 changed files with 296 additions and 0 deletions

View File

@@ -165,6 +165,23 @@ async def get_startup_task() -> InfoOut:
return InfoOut(data={"queueIdList": data})
@router.post(
"/webconfig",
summary="获取配置分享中心的配置信息",
response_model=InfoOut,
status_code=200,
)
async def get_web_config() -> InfoOut:
try:
data = await Config.get_web_config()
except Exception as e:
return InfoOut(
code=500, status="error", message=f"{type(e).__name__}: {str(e)}", data={}
)
return InfoOut(data={"WebConfig": data})
@router.post(
"/get/overview", summary="信息总览", response_model=InfoOut, status_code=200
)