docs: update API references to match implementation (#19334)

Fixed existing typos and documentation inconsistencies.
Corrected and clarified parameter types.
Improved parameter constraints and required/optional field descriptions.
Updated several parameter descriptions to better reflect their actual
behavior.
This commit is contained in:
YanZhang authored and GitHub committed 2026-09-07 20:04:10 +08:00
1 parent 77ef603208
commit 8ce74f3e30
2 files changed
+172 -131

No files matched your search

+38 -15
View File
@@ -22,17 +22,40 @@ pip install ragflow-sdk
## ERROR CODES
---
RAGFlow responses may contain both an HTTP status code and a business code in the JSON response body. These codes should be checked separately.
| Code | Message | Description |
|------|-----------------------|----------------------------|
| 400 | Bad Request | Invalid request parameters |
| 401 | Unauthorized | Unauthorized access |
| 403 | Forbidden | Access denied |
| 404 | Not Found | Resource not found |
| 500 | Internal Server Error | Server internal error |
| 1001 | Invalid Chunk ID | Invalid Chunk ID |
| 1002 | Chunk Update Failed | Chunk update failed |
### HTTP status codes
| Code | Meaning |
|------|---------|
| 200 | The HTTP request was processed successfully. Check the response body `code` for the business result. |
| 400 | Bad request |
| 401 | Unauthorized |
| 403 | Forbidden |
| 404 | Not found |
| 409 | Conflict |
| 500 | Internal server error |
### Response body codes
| Code | Meaning |
|------|---------|
| 0 | Success |
| 10 | Not effective |
| 100 | Exception error |
| 101 | Invalid request argument |
| 102 | Invalid or missing data |
| 103 | Operation error |
| 105 | Connection error |
| 106 | Operation still running |
| 108 | Permission error |
| 109 | Authentication error |
| 400 | Bad request |
| 401 | Unauthorized |
| 403 | Forbidden |
| 404 | Not found |
| 409 | Conflict |
| 500 | Server error |
---
@@ -1124,13 +1147,13 @@ Retrieves chunks from specified datasets.
#### Parameters
##### question: `string`, *Required*
##### question: `string`
The user query or query keywords. Defaults to `""`.
The user query or query keywords. Defaults to `""`. When an empty string is provided, the API returns an empty retrieval result.
##### dataset_ids: `list[str]`, *Required*
The IDs of the datasets to search. Defaults to `None`.
The IDs of the datasets to search. At least one dataset ID must be provided.
##### document_ids: `list[str]`
@@ -1138,11 +1161,11 @@ The IDs of the documents to search. Defaults to `None`. You must ensure all sele
##### page: `int`
The starting index for the documents to retrieve. Defaults to `1`.
The page number of the chunk retrieval results. Defaults to `1`.
##### page_size: `int`
The maximum number of chunks to retrieve. Defaults to `30`.
The maximum number of chunks returned on each page. Defaults to `30`.
##### similarity_threshold: `float`