From cc4e9fd6fbd60f79f5150cb4eb935d7be5481844 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A0=91=E8=90=8C=E8=8A=BD?= <3205788256@qq.com> Date: Sat, 16 May 2026 19:03:09 +0800 Subject: [PATCH] chore: sync local updates --- api-docs/infogenie-api-apifox/.gitignore | 4 + .../AI 模型应用/apifox.folder.json | 1 + .../AI 模型应用/对话/Chat 流式 SSE.http.yaml | 26 + .../AI 模型应用/对话/Chat 非流式.http.yaml | 22 + .../AI 模型应用/对话/apifox.folder.json | 1 + .../AI 模型应用/应用/Linux 命令建议.http.yaml | 16 + .../AI 模型应用/应用/Markdown 排版.http.yaml | 17 + .../AI 模型应用/应用/apifox.folder.json | 1 + .../AI 模型应用/应用/亲属称呼计算.http.yaml | 16 + .../AI 模型应用/应用/变量命名建议.http.yaml | 16 + .../AI 模型应用/应用/可用模型列表.http.yaml | 7 + .../AI 模型应用/应用/多语言翻译.http.yaml | 16 + .../AI 模型应用/应用/姓名分析.http.yaml | 15 + .../AI 模型应用/应用/现代文转文言.http.yaml | 17 + .../AI 模型应用/应用/表情符号生成.http.yaml | 16 + .../AI 模型应用/应用/诗歌生成.http.yaml | 17 + api-docs/infogenie-api-apifox/apifox.env.json | 12 + .../infogenie-api-apifox/apifox.meta.json | 7 + .../核心/apifox.folder.json | 1 + .../核心/健康检查.http.yaml | 3 + .../核心/服务信息.http.yaml | 3 + .../用户/apifox.folder.json | 1 + .../用户/用户资料.http.yaml | 7 + .../站点/60s 上游节点.http.yaml | 3 + .../站点/60s 隐藏功能列表.http.yaml | 3 + .../站点/AI 应用隐藏列表.http.yaml | 3 + .../站点/apifox.folder.json | 1 + .../站点/功能卡片点击 +1.http.yaml | 14 + .../站点/功能卡片点击统计.http.yaml | 3 + .../站点管理/apifox.folder.json | 1 + .../站点管理/写入 60s 隐藏列表.http.yaml | 15 + .../站点管理/写入 AI 应用隐藏列表.http.yaml | 15 + .../站点管理/写入 AI 运行时配置.http.yaml | 18 + .../站点管理/切换 60s 上游节点.http.yaml | 15 + .../站点管理/诊断信息.http.yaml | 7 + .../站点管理/读取 AI 运行时配置.http.yaml | 7 + .../认证/apifox.folder.json | 1 + .../认证/登录态检查.http.yaml | 8 + .../认证/登录态检查(匿名).http.yaml | 4 + api-docs/infogenie-api.json | 659 ++++++++++++++++++ 40 files changed, 1019 insertions(+) create mode 100644 api-docs/infogenie-api-apifox/.gitignore create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 流式 SSE.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 非流式.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/对话/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/Linux 命令建议.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/Markdown 排版.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/亲属称呼计算.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/变量命名建议.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/可用模型列表.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/多语言翻译.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/姓名分析.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/现代文转文言.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/表情符号生成.http.yaml create mode 100644 api-docs/infogenie-api-apifox/AI 模型应用/应用/诗歌生成.http.yaml create mode 100644 api-docs/infogenie-api-apifox/apifox.env.json create mode 100644 api-docs/infogenie-api-apifox/apifox.meta.json create mode 100644 api-docs/infogenie-api-apifox/核心/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/核心/健康检查.http.yaml create mode 100644 api-docs/infogenie-api-apifox/核心/服务信息.http.yaml create mode 100644 api-docs/infogenie-api-apifox/用户/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/用户/用户资料.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点/60s 上游节点.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点/60s 隐藏功能列表.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点/AI 应用隐藏列表.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/站点/功能卡片点击 +1.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点/功能卡片点击统计.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点管理/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/站点管理/写入 60s 隐藏列表.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点管理/写入 AI 应用隐藏列表.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点管理/写入 AI 运行时配置.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点管理/切换 60s 上游节点.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点管理/诊断信息.http.yaml create mode 100644 api-docs/infogenie-api-apifox/站点管理/读取 AI 运行时配置.http.yaml create mode 100644 api-docs/infogenie-api-apifox/认证/apifox.folder.json create mode 100644 api-docs/infogenie-api-apifox/认证/登录态检查.http.yaml create mode 100644 api-docs/infogenie-api-apifox/认证/登录态检查(匿名).http.yaml create mode 100644 api-docs/infogenie-api.json diff --git a/api-docs/infogenie-api-apifox/.gitignore b/api-docs/infogenie-api-apifox/.gitignore new file mode 100644 index 00000000..3247afc7 --- /dev/null +++ b/api-docs/infogenie-api-apifox/.gitignore @@ -0,0 +1,4 @@ +node_modules +.git +apifox.private.* +.apifox \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/apifox.folder.json b/api-docs/infogenie-api-apifox/AI 模型应用/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 流式 SSE.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 流式 SSE.http.yaml new file mode 100644 index 00000000..5cd143de --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 流式 SSE.http.yaml @@ -0,0 +1,26 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/chat/stream" +name: Chat 流式 SSE +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json + - name: Accept + value: text/event-stream + - name: Cache-Control + value: no-cache +requestBody: + type: application/json + data: |- + { + "messages": [ + { + "role": "user", + "content": "写一首四句短诗。" + } + ], + "provider": "deepseek", + "model": "deepseek-chat" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 非流式.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 非流式.http.yaml new file mode 100644 index 00000000..a1fbc847 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/对话/Chat 非流式.http.yaml @@ -0,0 +1,22 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/chat" +name: Chat 非流式 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "messages": [ + { + "role": "user", + "content": "用一句话介绍你自己。" + } + ], + "provider": "deepseek", + "model": "deepseek-chat" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/对话/apifox.folder.json b/api-docs/infogenie-api-apifox/AI 模型应用/对话/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/对话/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/Linux 命令建议.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/Linux 命令建议.http.yaml new file mode 100644 index 00000000..e74591f8 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/Linux 命令建议.http.yaml @@ -0,0 +1,16 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/linux-command" +name: Linux 命令建议 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "task_description": "查找当前目录下大于 10MB 的文件", + "difficulty_level": "beginner" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/Markdown 排版.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/Markdown 排版.http.yaml new file mode 100644 index 00000000..296dc1e6 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/Markdown 排版.http.yaml @@ -0,0 +1,17 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/markdown_formatting" +name: Markdown 排版 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "article_text": "第一段内容\n\n第二段内容", + "emoji_style": "balanced", + "markdown_option": "standard" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/apifox.folder.json b/api-docs/infogenie-api-apifox/AI 模型应用/应用/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/亲属称呼计算.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/亲属称呼计算.http.yaml new file mode 100644 index 00000000..5a84cb2e --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/亲属称呼计算.http.yaml @@ -0,0 +1,16 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/kinship-calculator" +name: 亲属称呼计算 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "relation_chain": "我妈妈的姐姐的儿子", + "dialects": ["粤语", "闽南语"] + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/变量命名建议.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/变量命名建议.http.yaml new file mode 100644 index 00000000..f26a1093 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/变量命名建议.http.yaml @@ -0,0 +1,16 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/variable-naming" +name: 变量命名建议 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "description": "存储用户最近一次登录时间的字段", + "language": "javascript" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/可用模型列表.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/可用模型列表.http.yaml new file mode 100644 index 00000000..1bfed0b0 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/可用模型列表.http.yaml @@ -0,0 +1,7 @@ +method: get +url: "{{baseUrl}}/api/aimodelapp/models" +name: 可用模型列表 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/多语言翻译.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/多语言翻译.http.yaml new file mode 100644 index 00000000..65f06092 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/多语言翻译.http.yaml @@ -0,0 +1,16 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/translation" +name: 多语言翻译 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "source_text": "Hello, world!", + "target_language": "zh-CN" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/姓名分析.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/姓名分析.http.yaml new file mode 100644 index 00000000..216a45f0 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/姓名分析.http.yaml @@ -0,0 +1,15 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/name-analysis" +name: 姓名分析 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "name": "张晨曦" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/现代文转文言.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/现代文转文言.http.yaml new file mode 100644 index 00000000..f1f8bce4 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/现代文转文言.http.yaml @@ -0,0 +1,17 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/classical_conversion" +name: 现代文转文言 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "modern_text": "今天天气很好,我们去公园散步。", + "style": "古雅", + "article_type": "散文" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/表情符号生成.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/表情符号生成.http.yaml new file mode 100644 index 00000000..f636d5ac --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/表情符号生成.http.yaml @@ -0,0 +1,16 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/expression-maker" +name: 表情符号生成 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "text": "今天答辩顺利通过了!", + "style": "mixed" + } diff --git a/api-docs/infogenie-api-apifox/AI 模型应用/应用/诗歌生成.http.yaml b/api-docs/infogenie-api-apifox/AI 模型应用/应用/诗歌生成.http.yaml new file mode 100644 index 00000000..fe0d4823 --- /dev/null +++ b/api-docs/infogenie-api-apifox/AI 模型应用/应用/诗歌生成.http.yaml @@ -0,0 +1,17 @@ +method: post +url: "{{baseUrl}}/api/aimodelapp/poetry" +name: 诗歌生成 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "theme": "春雨与江南", + "style": "现代诗", + "mood": "宁静" + } diff --git a/api-docs/infogenie-api-apifox/apifox.env.json b/api-docs/infogenie-api-apifox/apifox.env.json new file mode 100644 index 00000000..cf68a7a8 --- /dev/null +++ b/api-docs/infogenie-api-apifox/apifox.env.json @@ -0,0 +1,12 @@ +{ + "Local": { + "baseUrl": "http://127.0.0.1:5002", + "bearerToken": "", + "siteAdminToken": "" + }, + "Production": { + "baseUrl": "https://infogenie.api.shumengya.top", + "bearerToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhY2NvdW50Ijoic2h1bWVuZ3lhIiwiZXBvY2giOjAsImlzcyI6InNwcm91dGdhdGUiLCJzdWIiOiJzaHVtZW5neWEiLCJleHAiOjE3NzcyMDgxODIsImlhdCI6MTc3NjYwMzM4Mn0.VffffNCIWkp7X0GHo2xKkVFxTyEHdEXHWKu6UZF1xfM", + "siteAdminToken": "shumengya520" + } +} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/apifox.meta.json b/api-docs/infogenie-api-apifox/apifox.meta.json new file mode 100644 index 00000000..792a80ed --- /dev/null +++ b/api-docs/infogenie-api-apifox/apifox.meta.json @@ -0,0 +1,7 @@ +{ + "version": "1", + "name": "infogenie-api", + "description": "万象口袋(InfoGenie)Go 后端 API(infogenie-backend-go)。\n\n【环境】apifox.env.json 仅含 Local(APP_PORT 默认 5002)与 Production。在 Apifox 选中环境后调试。\n\n【变量】\n• bearerToken:萌芽认证中心 JWT(前端 localStorage token 或登录接口返回;需登录的接口已写 Authorization: Bearer {{bearerToken}})。\n• siteAdminToken:与后端 INFOGENIE_SITE_ADMIN_TOKEN 一致,管理端 GET/PUT /api/admin/site/* 使用请求头 X-Site-Admin-Token: {{siteAdminToken}}。\n\n【安全】勿将真实 token 提交到 Git;若曾把 JWT 写入仓库请尽快在认证中心作废并重新登录。\n\n【根路径】GET / 返回服务说明 JSON;详细健康与依赖探测见 GET /api/health。", + "type": "collection", + "ignore": [] +} diff --git a/api-docs/infogenie-api-apifox/核心/apifox.folder.json b/api-docs/infogenie-api-apifox/核心/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/核心/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/核心/健康检查.http.yaml b/api-docs/infogenie-api-apifox/核心/健康检查.http.yaml new file mode 100644 index 00000000..ff60fbc8 --- /dev/null +++ b/api-docs/infogenie-api-apifox/核心/健康检查.http.yaml @@ -0,0 +1,3 @@ +method: get +url: "{{baseUrl}}/api/health" +name: 健康检查 diff --git a/api-docs/infogenie-api-apifox/核心/服务信息.http.yaml b/api-docs/infogenie-api-apifox/核心/服务信息.http.yaml new file mode 100644 index 00000000..22318488 --- /dev/null +++ b/api-docs/infogenie-api-apifox/核心/服务信息.http.yaml @@ -0,0 +1,3 @@ +method: get +url: "{{baseUrl}}/" +name: 服务信息 diff --git a/api-docs/infogenie-api-apifox/用户/apifox.folder.json b/api-docs/infogenie-api-apifox/用户/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/用户/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/用户/用户资料.http.yaml b/api-docs/infogenie-api-apifox/用户/用户资料.http.yaml new file mode 100644 index 00000000..e5f4db2f --- /dev/null +++ b/api-docs/infogenie-api-apifox/用户/用户资料.http.yaml @@ -0,0 +1,7 @@ +method: get +url: "{{baseUrl}}/api/user/profile" +name: 用户资料 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} diff --git a/api-docs/infogenie-api-apifox/站点/60s 上游节点.http.yaml b/api-docs/infogenie-api-apifox/站点/60s 上游节点.http.yaml new file mode 100644 index 00000000..6ee8c6df --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点/60s 上游节点.http.yaml @@ -0,0 +1,3 @@ +method: get +url: "{{baseUrl}}/api/site/60s-source" +name: 60s 上游节点 diff --git a/api-docs/infogenie-api-apifox/站点/60s 隐藏功能列表.http.yaml b/api-docs/infogenie-api-apifox/站点/60s 隐藏功能列表.http.yaml new file mode 100644 index 00000000..c2134647 --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点/60s 隐藏功能列表.http.yaml @@ -0,0 +1,3 @@ +method: get +url: "{{baseUrl}}/api/site/60s-disabled" +name: 60s 隐藏功能列表 diff --git a/api-docs/infogenie-api-apifox/站点/AI 应用隐藏列表.http.yaml b/api-docs/infogenie-api-apifox/站点/AI 应用隐藏列表.http.yaml new file mode 100644 index 00000000..f80a5b0c --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点/AI 应用隐藏列表.http.yaml @@ -0,0 +1,3 @@ +method: get +url: "{{baseUrl}}/api/site/ai-model-disabled" +name: AI 应用隐藏列表 diff --git a/api-docs/infogenie-api-apifox/站点/apifox.folder.json b/api-docs/infogenie-api-apifox/站点/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/站点/功能卡片点击 +1.http.yaml b/api-docs/infogenie-api-apifox/站点/功能卡片点击 +1.http.yaml new file mode 100644 index 00000000..662c2bfb --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点/功能卡片点击 +1.http.yaml @@ -0,0 +1,14 @@ +method: post +url: "{{baseUrl}}/api/site/feature-card-clicks/increment" +name: 功能卡片点击 +1 +parameters: + header: + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "section": "60sapi", + "item_id": "example-item-id" + } diff --git a/api-docs/infogenie-api-apifox/站点/功能卡片点击统计.http.yaml b/api-docs/infogenie-api-apifox/站点/功能卡片点击统计.http.yaml new file mode 100644 index 00000000..fbd729a5 --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点/功能卡片点击统计.http.yaml @@ -0,0 +1,3 @@ +method: get +url: "{{baseUrl}}/api/site/feature-card-clicks?section=60sapi" +name: 功能卡片点击统计 diff --git a/api-docs/infogenie-api-apifox/站点管理/apifox.folder.json b/api-docs/infogenie-api-apifox/站点管理/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/站点管理/写入 60s 隐藏列表.http.yaml b/api-docs/infogenie-api-apifox/站点管理/写入 60s 隐藏列表.http.yaml new file mode 100644 index 00000000..bb6db2ca --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/写入 60s 隐藏列表.http.yaml @@ -0,0 +1,15 @@ +method: put +url: "{{baseUrl}}/api/admin/site/60s-disabled" +name: 写入 60s 隐藏列表 +parameters: + header: + - name: X-Site-Admin-Token + value: "{{siteAdminToken}}" + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "disabled": [] + } diff --git a/api-docs/infogenie-api-apifox/站点管理/写入 AI 应用隐藏列表.http.yaml b/api-docs/infogenie-api-apifox/站点管理/写入 AI 应用隐藏列表.http.yaml new file mode 100644 index 00000000..8ec577d6 --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/写入 AI 应用隐藏列表.http.yaml @@ -0,0 +1,15 @@ +method: put +url: "{{baseUrl}}/api/admin/site/ai-model-disabled" +name: 写入 AI 应用隐藏列表 +parameters: + header: + - name: X-Site-Admin-Token + value: "{{siteAdminToken}}" + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "disabled": [] + } diff --git a/api-docs/infogenie-api-apifox/站点管理/写入 AI 运行时配置.http.yaml b/api-docs/infogenie-api-apifox/站点管理/写入 AI 运行时配置.http.yaml new file mode 100644 index 00000000..f2d1a041 --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/写入 AI 运行时配置.http.yaml @@ -0,0 +1,18 @@ +method: put +url: "{{baseUrl}}/api/admin/site/ai-runtime" +name: 写入 AI 运行时配置 +parameters: + header: + - name: X-Site-Admin-Token + value: "{{siteAdminToken}}" + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "api_base": "", + "api_key": "", + "default_model": "", + "default_provider": "deepseek" + } diff --git a/api-docs/infogenie-api-apifox/站点管理/切换 60s 上游节点.http.yaml b/api-docs/infogenie-api-apifox/站点管理/切换 60s 上游节点.http.yaml new file mode 100644 index 00000000..54415e77 --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/切换 60s 上游节点.http.yaml @@ -0,0 +1,15 @@ +method: put +url: "{{baseUrl}}/api/admin/site/60s-source" +name: 切换 60s 上游节点 +parameters: + header: + - name: X-Site-Admin-Token + value: "{{siteAdminToken}}" + - name: Content-Type + value: application/json +requestBody: + type: application/json + data: |- + { + "source_id": "self" + } diff --git a/api-docs/infogenie-api-apifox/站点管理/诊断信息.http.yaml b/api-docs/infogenie-api-apifox/站点管理/诊断信息.http.yaml new file mode 100644 index 00000000..fa94e284 --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/诊断信息.http.yaml @@ -0,0 +1,7 @@ +method: get +url: "{{baseUrl}}/api/admin/site/diagnostics" +name: 诊断信息 +parameters: + header: + - name: X-Site-Admin-Token + value: "{{siteAdminToken}}" diff --git a/api-docs/infogenie-api-apifox/站点管理/读取 AI 运行时配置.http.yaml b/api-docs/infogenie-api-apifox/站点管理/读取 AI 运行时配置.http.yaml new file mode 100644 index 00000000..4cca4f9e --- /dev/null +++ b/api-docs/infogenie-api-apifox/站点管理/读取 AI 运行时配置.http.yaml @@ -0,0 +1,7 @@ +method: get +url: "{{baseUrl}}/api/admin/site/ai-runtime" +name: 读取 AI 运行时配置 +parameters: + header: + - name: X-Site-Admin-Token + value: "{{siteAdminToken}}" diff --git a/api-docs/infogenie-api-apifox/认证/apifox.folder.json b/api-docs/infogenie-api-apifox/认证/apifox.folder.json new file mode 100644 index 00000000..9e26dfee --- /dev/null +++ b/api-docs/infogenie-api-apifox/认证/apifox.folder.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/api-docs/infogenie-api-apifox/认证/登录态检查.http.yaml b/api-docs/infogenie-api-apifox/认证/登录态检查.http.yaml new file mode 100644 index 00000000..19efaaa7 --- /dev/null +++ b/api-docs/infogenie-api-apifox/认证/登录态检查.http.yaml @@ -0,0 +1,8 @@ +method: get +url: "{{baseUrl}}/api/auth/check" +name: 登录态检查 +description: 携带 JWT;后端向认证中心校验,与前端会话一致。 +parameters: + header: + - name: Authorization + value: Bearer {{bearerToken}} diff --git a/api-docs/infogenie-api-apifox/认证/登录态检查(匿名).http.yaml b/api-docs/infogenie-api-apifox/认证/登录态检查(匿名).http.yaml new file mode 100644 index 00000000..ad7b2406 --- /dev/null +++ b/api-docs/infogenie-api-apifox/认证/登录态检查(匿名).http.yaml @@ -0,0 +1,4 @@ +method: get +url: "{{baseUrl}}/api/auth/check" +name: 登录态检查(无 Token) +description: 可选;不带 Authorization 时由 OptionalJWTAuth 放行,用于对比未登录响应。 diff --git a/api-docs/infogenie-api.json b/api-docs/infogenie-api.json new file mode 100644 index 00000000..8dd052d4 --- /dev/null +++ b/api-docs/infogenie-api.json @@ -0,0 +1,659 @@ +{ + "info": { + "_postman_id": "9e4d5b21-ac5f-5d32-b8e2-infogenie01", + "name": "infogenie-api", + "description": "万象口袋(InfoGenie)后端 API 合集:健康检查、认证与用户、站点配置、管理端与 AI 应用。\n集合变量仅含 baseUrl(生产默认)。请在运行环境(如 Apifox「环境」)中配置 bearerToken(萌芽 JWT)与 siteAdminToken(站点管理口令),勿在集合里重复定义同名变量,以免空值覆盖环境。\n需登录的接口已显式携带 Authorization: Bearer {{bearerToken}}。", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" + }, + "variable": [ + { + "key": "baseUrl", + "value": "https://infogenie.api.shumengya.top" + }, + { + "key": "bearerToken", + "value": "" + } + ], + "item": [ + { + "name": "core", + "description": "服务根路径与健康检查。", + "item": [ + { + "name": "服务信息", + "request": { + "method": "GET", + "header": [], + "url": "{{baseUrl}}/", + "description": "返回服务说明、版本与主要 API 路径摘要。" + } + }, + { + "name": "健康检查", + "request": { + "method": "GET", + "header": [], + "url": "{{baseUrl}}/api/health", + "description": "数据库、Redis、60s 上游轻量探测与整体运行状态。" + } + } + ] + }, + { + "name": "auth", + "description": "登录态检测(可选 Token)。", + "item": [ + { + "name": "登录态检查", + "request": { + "method": "GET", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + } + ], + "url": "{{baseUrl}}/api/auth/check", + "description": "OptionalJWT:填写 bearerToken 可校验登录态;留空则返回 logged_in: false。" + } + } + ] + }, + { + "name": "user", + "description": "已登录用户资料(需萌芽认证 Token)。", + "item": [ + { + "name": "用户资料", + "request": { + "method": "GET", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + } + ], + "url": "{{baseUrl}}/api/user/profile", + "description": "返回账号、昵称、邮箱、头像、等级、萌币与签到信息。" + } + } + ] + }, + { + "name": "site", + "description": "站点公开配置与功能卡片统计(无需登录)。", + "item": [ + { + "name": "60s 隐藏功能列表", + "request": { + "method": "GET", + "header": [], + "url": "{{baseUrl}}/api/site/60s-disabled", + "description": "当前在前端隐藏的 60s 功能 id 列表。" + } + }, + { + "name": "60s 上游节点", + "request": { + "method": "GET", + "header": [], + "url": "{{baseUrl}}/api/site/60s-source", + "description": "当前站点使用的 60s API 上游 base_url 与标签。" + } + }, + { + "name": "AI 应用隐藏列表", + "request": { + "method": "GET", + "header": [], + "url": "{{baseUrl}}/api/site/ai-model-disabled", + "description": "当前隐藏的 AI 应用 id 列表。" + } + }, + { + "name": "功能卡片点击统计", + "request": { + "method": "GET", + "header": [], + "url": "{{baseUrl}}/api/site/feature-card-clicks?section=60sapi", + "description": "查询某板块下各 item 点击次数。section:60sapi | smallgame | toolbox | aimodel。" + } + }, + { + "name": "功能卡片点击 +1", + "request": { + "method": "POST", + "header": [ + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"section\": \"60sapi\",\n \"item_id\": \"example-item-id\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/site/feature-card-clicks/increment", + "description": "记录一次卡片点击并返回最新计数。" + } + } + ] + }, + { + "name": "admin-site", + "description": "站点管理(需请求头 X-Site-Admin-Token,与 INFOGENIE_SITE_ADMIN_TOKEN 一致)。", + "item": [ + { + "name": "写入 60s 隐藏列表", + "request": { + "method": "PUT", + "header": [ + { + "key": "X-Site-Admin-Token", + "value": "{{siteAdminToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"disabled\": []\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/admin/site/60s-disabled", + "description": "全量替换隐藏的 60s 功能 id 列表。" + } + }, + { + "name": "切换 60s 上游节点", + "request": { + "method": "PUT", + "header": [ + { + "key": "X-Site-Admin-Token", + "value": "{{siteAdminToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"source_id\": \"self\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/admin/site/60s-source", + "description": "source_id:self(萌芽节点)或 official(官方节点)。" + } + }, + { + "name": "写入 AI 应用隐藏列表", + "request": { + "method": "PUT", + "header": [ + { + "key": "X-Site-Admin-Token", + "value": "{{siteAdminToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"disabled\": []\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/admin/site/ai-model-disabled", + "description": "全量替换隐藏的 AI 应用 id 列表。" + } + }, + { + "name": "读取 AI 运行时配置", + "request": { + "method": "GET", + "header": [ + { + "key": "X-Site-Admin-Token", + "value": "{{siteAdminToken}}", + "type": "text" + } + ], + "url": "{{baseUrl}}/api/admin/site/ai-runtime", + "description": "读取数据库中的 AI 上游地址与密钥脱敏信息。" + } + }, + { + "name": "写入 AI 运行时配置", + "request": { + "method": "PUT", + "header": [ + { + "key": "X-Site-Admin-Token", + "value": "{{siteAdminToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"api_base\": \"\",\n \"api_key\": \"\",\n \"default_model\": \"\",\n \"default_provider\": \"deepseek\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/admin/site/ai-runtime", + "description": "api_key 留空或不传则保留原密钥;勿将脱敏后的 **** 当作新密钥提交。" + } + }, + { + "name": "诊断信息", + "request": { + "method": "GET", + "header": [ + { + "key": "X-Site-Admin-Token", + "value": "{{siteAdminToken}}", + "type": "text" + } + ], + "url": "{{baseUrl}}/api/admin/site/diagnostics", + "description": "连接配置摘要(不含密码/密钥明文)。" + } + } + ] + }, + { + "name": "aimodel", + "description": "AI 模型应用(需萌芽认证 Token)。", + "item": [ + { + "name": "对话", + "item": [ + { + "name": "Chat 非流式", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"messages\": [\n {\n \"role\": \"user\",\n \"content\": \"用一句话介绍你自己。\"\n }\n ],\n \"provider\": \"deepseek\",\n \"model\": \"deepseek-chat\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/chat", + "description": "OpenAI 风格 messages;provider/model 须在服务端白名单内。" + } + }, + { + "name": "Chat 流式 SSE", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + }, + { + "key": "Accept", + "value": "text/event-stream", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"messages\": [\n {\n \"role\": \"user\",\n \"content\": \"写一首四句短诗。\"\n }\n ],\n \"provider\": \"deepseek\",\n \"model\": \"deepseek-chat\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/chat/stream", + "description": "返回 text/event-stream(SSE);客户端需按流读取。" + } + } + ] + }, + { + "name": "应用", + "item": [ + { + "name": "姓名分析", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"name\": \"张晨曦\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/name-analysis", + "description": "姓名学与文化含义分析。" + } + }, + { + "name": "变量命名建议", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"description\": \"存储用户最近一次登录时间的字段\",\n \"language\": \"javascript\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/variable-naming", + "description": "按多种命名风格生成变量名建议。" + } + }, + { + "name": "诗歌生成", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"theme\": \"春雨与江南\",\n \"style\": \"现代诗\",\n \"mood\": \"宁静\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/poetry", + "description": "按主题、风格、情感基调作诗。" + } + }, + { + "name": "多语言翻译", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"source_text\": \"Hello, world!\",\n \"target_language\": \"zh-CN\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/translation", + "description": "翻译为指定目标语言(JSON 结构化结果)。" + } + }, + { + "name": "现代文转文言", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"modern_text\": \"今天天气很好,我们去公园散步。\",\n \"style\": \"古雅\",\n \"article_type\": \"散文\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/classical_conversion", + "description": "现代文转文言文,返回 JSON 结构。" + } + }, + { + "name": "表情符号生成", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"text\": \"今天答辩顺利通过了!\",\n \"style\": \"mixed\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/expression-maker", + "description": "根据文案生成 emoji/颜文字等建议;style 如 mixed、emoji、kaomoji 等。" + } + }, + { + "name": "Linux 命令建议", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"task_description\": \"查找当前目录下大于 10MB 的文件\",\n \"difficulty_level\": \"beginner\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/linux-command", + "description": "根据任务描述生成命令与安全提示等 JSON。" + } + }, + { + "name": "Markdown 排版", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"article_text\": \"第一段内容\\n\\n第二段内容\",\n \"emoji_style\": \"balanced\",\n \"markdown_option\": \"standard\"\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/markdown_formatting", + "description": "在不改写原文的前提下输出结构化 Markdown。" + } + }, + { + "name": "亲属称呼计算", + "request": { + "method": "POST", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + }, + { + "key": "Content-Type", + "value": "application/json", + "type": "text" + } + ], + "body": { + "mode": "raw", + "raw": "{\n \"relation_chain\": \"我妈妈的姐姐的儿子\",\n \"dialects\": [\"粤语\", \"闽南语\"]\n}", + "options": { + "raw": { + "language": "json" + } + } + }, + "url": "{{baseUrl}}/api/aimodelapp/kinship-calculator", + "description": "解析关系链,给出普通话及方言称呼 JSON。" + } + }, + { + "name": "可用模型列表", + "request": { + "method": "GET", + "header": [ + { + "key": "Authorization", + "value": "Bearer {{bearerToken}}", + "type": "text" + } + ], + "url": "{{baseUrl}}/api/aimodelapp/models", + "description": "返回服务端允许的 provider 与 model 白名单。" + } + } + ] + } + ] + } + ] +}