智信-agent
  1. 知识库管理
智信-agent
  • 文件分析
    • 文件解析接口
      POST
    • 文本分段测试接口
      POST
    • 二进制文件
      POST
  • 知识库管理
    • 知识库初始化
      POST
    • 知识库召回测试
      POST
    • 知识库查询
      POST
    • 知识库文件添加
      POST
  • 工作流
    • AI生成prompt
      POST
    • 工作流运行
      POST
    • 单节点运行
      POST
    • 工作流保存接口
      POST
  • MCP管理
    • 建立MCP服务器
      POST
    • MCP服务器工具的添加
      POST
    • MCP服务器工具的删除
      POST
    • MCP服务器工具的修改
      POST
    • 修改服务器名称和描述
      POST
    • 关闭MCP服务器
      POST
    • 查看所有的工具
      POST
    • 查询当前活跃的mcp服务器信息
      GET
    • 使用指定工具
      POST
  • 数据库开发
    • 数据库内部接口
      • 接口整合
      • 自然语言及SQL执行
      • schma查询
      • 单表的字段描述查询
      • all
    • 数据库工作流运行
      • 数据库工作流保存
      • 数据库单节点运行
  • mineru
    POST
  1. 知识库管理

知识库文件添加

开发中
开发环境
http://172.29.50.10:2333
开发环境
http://172.29.50.10:2333
POST
/zhixin_agent/knowledge_database/append

请求参数

Body 参数application/json
data_source
object 
必需
type
string 
必需
info_list
object 
必需
user_info
object 
必需
user_name
string 
必需
user_id
string 
必需
dataset_id
string 
必需
doc_form
string 
必需
doc_language
string 
必需
示例
{
    "data_source": {
        "type": "notion_import",
        "info_list": {
            "data_source_type": "notion_import",
            "file_info_list": {
                "file_ids": [
                    "c969a6f5-89e5-41b6-8dbc-cff937ec52b2",
                    "c969a6f6-89e5-41b6-8dbc-cff937ec52b2"
                ]
            }
        }
    },
    "user_info": {
        "user_name": "hongxm",
        "user_id": "0001"
    },
    "dataset_id": "20f02d52-450c-4039-a404-88d5d137a6d7",
    "doc_form": "text_model",
    "doc_language": "Chinese"
}

示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
cURL
curl --location --request POST 'http://172.29.50.10:2333/zhixin_agent/knowledge_database/append' \
--header 'Content-Type: application/json' \
--data-raw '{
    "data_source": {
        "type": "notion_import",
        "info_list": {
            "data_source_type": "notion_import",
            "file_info_list": {
                "file_ids": [
                    "c969a6f5-89e5-41b6-8dbc-cff937ec52b2",
                    "c969a6f6-89e5-41b6-8dbc-cff937ec52b2"
                ]
            }
        }
    },
    "user_info": {
        "user_name": "hongxm",
        "user_id": "0001"
    },
    "dataset_id": "20f02d52-450c-4039-a404-88d5d137a6d7",
    "doc_form": "text_model",
    "doc_language": "Chinese"
}'

返回响应

🟢200成功
application/json
Body
documents
array [object {23}] 
必需
id
string 
可选
position
integer 
可选
data_source_type
string 
可选
data_source_info
null 
可选
data_source_detail_dict
null 
可选
dataset_process_rule_id
string 
可选
name
string 
可选
created_from
string 
可选
created_by
string 
可选
created_at
integer 
可选
tokens
integer 
可选
indexing_status
string 
可选
error
null 
可选
enabled
boolean 
可选
disabled_at
null 
可选
disabled_by
null 
可选
archived
boolean 
可选
display_status
null 
可选
word_count
integer 
可选
hit_count
integer 
可选
doc_form
string 
可选
doc_metadata
null 
可选
file_id
string 
可选
batch
string 
必需
status
integer 
必需
示例
{
    "documents": [
        {
            "id": "8b786374-0223-4ed6-bb60-c760c7bf5015",
            "position": 1,
            "data_source_type": "notion_import",
            "data_source_info": null,
            "data_source_detail_dict": null,
            "dataset_process_rule_id": "d78fa9ef-50e1-4460-8245-41a648784e18",
            "name": "汽车以旧换新补贴实施细则.docx",
            "created_from": "web",
            "created_by": "0001",
            "created_at": 1745869007,
            "tokens": 0,
            "indexing_status": "waiting",
            "error": null,
            "enabled": true,
            "disabled_at": null,
            "disabled_by": null,
            "archived": false,
            "display_status": null,
            "word_count": 0,
            "hit_count": 0,
            "doc_form": "text_model",
            "doc_metadata": null,
            "file_id": "c969a6f6-89e5-41b6-8dbc-cff937ec52b2"
        }
    ],
    "batch": "20250429113647662969",
    "status": 200
}
修改于 2025-04-25 06:42:11
上一页
知识库查询
下一页
AI生成prompt
Built with