All Products
Search
Document Center

Tablestore:Update a knowledge base

Last Updated:Sep 24, 2026

Use the UpdateKnowledgeBase API to update the description, tags, or retrieval configuration of a knowledge base. At least one of description, tags, or retrievalConfiguration must be specified; otherwise, an error is returned.

Prerequisites

  • An AgentStorage instance has been created and is in the normal state, and the instance endpoint and instance name have been obtained.

  • An API Key has been created.

  • The knowledge base to be updated must already exist.

Request parameters

Parameter

Type

Description

knowledgeBaseName

string

The name of the knowledge base. (Required)

description

string

The updated description. Maximum size: 4 KB.

tags

list<string>

The updated tags.

retrievalConfiguration

object

The updated default retrieval configuration.

Request example

When you use API Key authentication, pass the instance name and API Key in the x-ots-instancename and x-ots-apikey request headers.

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": "Updated description",
  "tags": ["launched"]
}'

Response

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