Updated on 2025-08-13 GMT+08:00

Querying the Dialog History List

Function

Query the historical issue list. The information includes the dialog ID, question, username, and dialog start time.

URI

GET /v1/koosearch/chat-history

Table 1 Query Parameters

Parameter

Mandatory

Type

Description

user_name

No

String

Username.

repo_id

No

String

Knowledge base ID.

How to obtain:

Log in to the KooSearch experience platform. In the navigation tree on the left, choose Knowledge Bases to view knowledge base IDs. Each knowledge base has a unique ID stored in the vector database.

chat_id

No

String

Chat ID.

page_num

No

Integer

Request page number.

page_size

No

Integer

Response result page size specified by the request, for example, 5 records/page or 10 records/page.

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Parameter description:

Token used for API authentication. For how to obtain the token, see section 3.2 "Authentication."

Constraints:

N/A.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

total

Integer

Total number of session histories.

size

Integer

Number of records returned on the current page.

pages

Integer

Total number of pages

current

Integer

Current page number.

optimize_count_sql

Boolean

This parameter is not used currently.

search_count

Boolean

This parameter is not used currently.

records

Array of ChatHistoryRecordInfo objects

Session history details.

Table 4 ChatHistoryRecordInfo

Parameter

Type

Description

chat_id

String

Chat ID, which uniquely identifies a chat.

knowledge_repo_id

String

Knowledge base ID, which identifies the knowledge base referenced by the current chat.

slave_repo_id

String

ID of the secondary knowledge base.

chat_title

String

Query in the current chat.

create_date_time

String

Timestamp when a chat occurred

project_id

String

Project ID. It can contain 1 to 64 characters. Only numbers, letters, hyphens (-), and underscores (_) are allowed. The value must start with a letter. Reserved field. You can contact the personnel responsible for enabling the service to obtain the value of this field.

is_del

Integer

Whether the current chat is deleted. 0: not deleted; 1: deleted.

Example Requests

None

Example Responses

Status code: 200

A success message is displayed.

{
  "records" : [ {
    "chat_id" : "8080de56-be09-4e80-a9e3-efe1e0505d16",
    "knowledge_repo_id" : "d848a560-6c71-4c87-ab3f-8b6e63ebbe62",
    "chat_title" : "Security mechanism testing",
    "create_date_time" : "1731052459260",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0,
    "slave_repo_id" : "09d83dce-4379-47d6-8753-c0fb76c360a3,f4b45b6c-1331-411c-9d0a-adfc8a55877b"
  }, {
    "chat_id" : "0c11fab3-2a9e-4ceb-842b-178ae21b302d",
    "knowledge_repo_id" : "d848a560-6c71-4c87-ab3f-8b6e63ebbe62",
    "chat_title" : "What are the differences between Hoya and Hoya carnosa?",
    "create_date_time" : "1731051914932",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "bb7fbd8a-ec5a-4d23-a6f3-0188d2b34377",
    "knowledge_repo_id" : "d848a560-6c71-4c87-ab3f-8b6e63ebbe62",
    "chat_title" : "Introduction to Lithops",
    "create_date_time" : "1731050885407",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "188eaa84-c09a-46a5-bade-f6301a9b3046",
    "knowledge_repo_id" : "d848a560-6c71-4c87-ab3f-8b6e63ebbe62",
    "chat_title" : "What is a succulent plant?",
    "create_date_time" : "1731050363161",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "f939c01e-8042-49bb-b207-6575f98bbaeb",
    "knowledge_repo_id" : "acd90739-2e22-4870-b2db-35018699b623",
    "chat_title" : "What are the most common car engine problems?",
    "create_date_time" : "1731049696207",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "fb12825c-1f93-487e-b5ef-e03f711a4219",
    "knowledge_repo_id" : "09d83dce-4379-47d6-8753-c0fb76c360a3",
    "chat_title" : "What is the content summary of Development and Analysis of Fast-Charging Model of Electric Vehicles?",
    "create_date_time" : "1731049167914",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "b267029c-9081-421d-8df2-36941a35f167",
    "knowledge_repo_id" : "09d83dce-4379-47d6-8753-c0fb76c360a3",
    "chat_title" : "What is the content summary of Development and Analysis of Fast-Charging Model of Electric Vehicles?",
    "create_date_time" : "1731049057770",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "ea64df7f-2a43-4158-a502-d74bcf438ab6",
    "knowledge_repo_id" : "09d83dce-4379-47d6-8753-c0fb76c360a3",
    "chat_title" : "What are the standards for evaluating the cruising range and energy consumption of pure electric passenger cars in China?",
    "create_date_time" : "1731048963883",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "0227a870-8713-4a09-9253-2347d715bcd6",
    "knowledge_repo_id" : "09d83dce-4379-47d6-8753-c0fb76c360a3",
    "chat_title" : "What are the standards for evaluating the cruising range and energy consumption of pure electric passenger cars in China?",
    "create_date_time" : "1731048945303",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  }, {
    "chat_id" : "bb5e22ca-42a0-453a-aef7-776ecc937eb0",
    "knowledge_repo_id" : "09d83dce-4379-47d6-8753-c0fb76c360a3",
    "chat_title" : "What are the standards for evaluating the cruising range and energy consumption of pure electric passenger cars in China?",
    "create_date_time" : "1731048825929",
    "project_id" : "b25446daeb1a41a7953c5deba2b2677a",
    "is_del" : 0
  } ],
  "total" : 40798,
  "size" : 10,
  "current" : 1,
  "pages" : 4080
}

Status Codes

Status Code

Description

200

A success message is displayed.

Error Codes

See Error Codes.