全部产品
Search
文档中心

表格存储:更新知识库

更新时间:Oct 21, 2026

使用 UpdateKnowledgeBase 接口更新知识库的描述、标签或检索配置。`description`、`tags`、`retrievalConfiguration` 至少填一个,否则报错。

前提条件

  • 已创建 AgentStorage 实例且状态为 normal,并获取实例访问地址(endpoint)和实例名。

  • 已创建 API Key。

  • 待更新的知识库已存在。

请求参数

参数

类型

说明

knowledgeBaseName

string

知识库名称(必填)

description

string

更新描述信息,最大 4KB

tags

list<string>

更新标签

retrievalConfiguration

object

更新默认检索配置

请求示例

使用 API Key 认证时,通过 x-ots-instancename 和 x-ots-apikey 请求头传入实例名和 API Key。

curl -X POST https://<endpoint>/UpdateKnowledgeBase \
  -H "x-ots-instancename: <instance-name>" \
  -H "x-ots-apikey: <your-api-key>" \
  -H "Content-Type: application/json" \
  -d '{
  "knowledgeBaseName": "product_docs_kb",
  "description": "更新后的描述",
  "tags": ["上线"]
}'

响应

{"code":"SUCCESS","data":{},"message":"succeed"}