2.5.4-Paragraph text Knowledge Query Batch
1. Overview
Interface name: Batch query of paragraph text knowledge
Version number: v1.0.0
2. Information
Request method: GET
Request URL: https://DOMAIN/openapi/v1/knowledge/text/
Domain: Refer to "Service address description"
3. Request parameters
Request header http header field:
Content-Type
string
Yes
Fixedapplication/json
cybertron-robot-key
string
Yes
Robot key
cybertron-robot-token
string
Yes
Robot token
Request Query field:
username
string
Yes
User account
knowledge_base_id
string
Yes
Knowledge Base id
folder_id
string
Yes
folder id
page
int
Yes
Number of pages, default is 1
pagesize
int
No
The number of results returned per page, default is 10
4. Response field description
HTTP status code: 200 OK
Response field description:
code
string
"000000" is normal, other exceptions
message
string
Status description
data
object
message body
total
int
Total record number
page
int
Current page number
page_size
int
Records per page
has_next
bool
Is it possible to turn the page backwards
has_previous
bool
Can I turn the page forward
max_page_num
int
Total page count
list
array
content
5. Example
Request Example:
curl 'https://_DOMAIN_/openapi/v1/knowledge/text/?username=me@host.com&knowledge_base_id=324&folder_id=2902' \
-H 'Content-Type: application/json' \
-H 'cybertron-robot-key: l8ia2IOc*************Z724%2BU%3D' \
-H 'cybertron-robot-token: MTc0Mzk5****************************************cGRCUTg9' \
-X GET -d '{}'Response example:
{
"code": "000000",
"message": "ok",
"data": {
"total": 9,
"list": [
{
"id": 3033,
"knowledge_image_list": [
"https://bucket1.some-host.com/api/app/cybertron/knowledge_file/image/knowledge/paragraph_text_img/172180700265d0ffb0-e821-44f4-9a12-be289220b151.jpeg"
],
"creator_name": "zhengdong.zhou",
"editor_name": "zhengdong.zhou",
"text_content": "v1 ****Return**[[--ContentED.LRyG4bM8gq7xI9cnNfEsX5||2022 Foreign Currency Exchange Discount Activities Overview||KM1109505||Article--]]**\n---\n**Abstract**\nThis article introduces the discount details of 2Q liquid financial management or online financial management foreign exchange transactions in 2022 effective from April 1 - June 30, 2022.\n**Detailed information**\n**Promotion period**|\n* April 1 - June 30, 2022",
"data_source": 1,
"create_time": "2024-07-24 16:57:31",
"update_time": "2024-07-24 17:00:12",
"knowledge_image": "{\"172180700265d0ffb0-e821-44f4-9a12-be289220b151.jpeg\": \"172180700265d0ffb0-e821-44f4-9a12-be289220b151.jpeg\"}",
"emb_status": 2,
"folder": 2902,
"knowledge_base": 324,
"knowledge_provider": 61,
"editor": 61
},
{
"id": 3032,
"knowledge_image_list": [],
"creator_name": "zhengdong.zhou",
"editor_name": "",
"text_content": "****Return**[[--ContentED.LRyG4bM8gq7xI9cnNfEsX5||2022 Foreign Currency Exchange Discount Activities Overview||KM1109505||Article--]]**\n---\n**Abstract**\nThis article introduces the discount details of 2Q liquid financial management or online financial management foreign exchange transactions in 2022 effective from April 1 - June 30, 2022.\n**Detailed information**\n**Promotion period**|\n* April 1 - June 30, 2022\n",
"data_source": 1,
"create_time": "2024-07-24 16:52:47",
"update_time": "2024-07-24 16:52:49",
"knowledge_image": "[]",
"emb_status": 2,
"folder": 2902,
"knowledge_base": 324,
"knowledge_provider": 61,
"editor": null
}
],
"page": 1,
"page_size": 2,
"has_next": true,
"has_previous": false,
"max_page_num": 5
}
}