Upload: structured data
Function
This API is used to upload structured data files to OBS for batch processing.
URI
POST /v1/koosearch/repos/{repo_id}/structured-data
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
repo_id |
Yes |
String |
Knowledge base ID. The value is a string of 1 to 64 characters and can contain only digits, letters, hyphens (-), and underscores (_). 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. |
Request 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. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
file |
Yes |
File |
Only JSON files can be uploaded. |
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
file_id |
String |
File ID. |
Status code: 400
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
|
|
error_msg |
String |
Error description |
Status code: 500
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
|
|
error_msg |
String |
Error description |
Example Requests
POST https://{endpoint}/v1/koosearch/repos/36b6d979-7f98-4fda-b8b5-d7d0cc95d296/structured-data
file
Example Responses
Status code: 200
Response body of the API for uploading documents.
{
"file_id" : "60fa0fbf-a809-4e4e-8d26-ec389a497bf4"
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Response body of the API for uploading documents. |
|
400 |
Invalid parameters |
|
500 |
Internal error |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot