mirror of
https://github.com/langgenius/dify.git
synced 2026-05-30 16:00:32 -04:00
refactor(api): migrate console.datasets.metadata to BaseModel (#36450)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
@@ -4413,9 +4413,9 @@ Initialize dataset with documents
|
||||
#### GET
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Success |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Built-in fields retrieved successfully | [DatasetMetadataBuiltInFieldsResponse](#datasetmetadatabuiltinfieldsresponse) |
|
||||
|
||||
### /datasets/notion-indexing-estimate
|
||||
|
||||
@@ -4730,9 +4730,9 @@ then asynchronously generates summary indexes for the provided documents.
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Success | [SimpleResultResponse](#simpleresultresponse) |
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 204 | Documents metadata updated successfully |
|
||||
|
||||
### /datasets/{dataset_id}/documents/status/{action}/batch
|
||||
|
||||
@@ -5342,9 +5342,9 @@ Get dataset indexing status
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Success |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Metadata retrieved successfully | [DatasetMetadataListResponse](#datasetmetadatalistresponse) |
|
||||
|
||||
#### POST
|
||||
##### Parameters
|
||||
@@ -5356,9 +5356,9 @@ Get dataset indexing status
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Success |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 201 | Metadata created successfully | [DatasetMetadataResponse](#datasetmetadataresponse) |
|
||||
|
||||
### /datasets/{dataset_id}/metadata/built-in/{action}
|
||||
|
||||
@@ -5372,9 +5372,9 @@ Get dataset indexing status
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Success | [SimpleResultResponse](#simpleresultresponse) |
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 204 | Action completed successfully |
|
||||
|
||||
### /datasets/{dataset_id}/metadata/{metadata_id}
|
||||
|
||||
@@ -5403,9 +5403,9 @@ Get dataset indexing status
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Success |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Metadata updated successfully | [DatasetMetadataResponse](#datasetmetadataresponse) |
|
||||
|
||||
### /datasets/{dataset_id}/notion/sync
|
||||
|
||||
@@ -11733,6 +11733,43 @@ Condition detail
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| keyword_weight | number | | No |
|
||||
|
||||
#### DatasetMetadataBuiltInFieldResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| name | string | | Yes |
|
||||
| type | string | | Yes |
|
||||
|
||||
#### DatasetMetadataBuiltInFieldsResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| fields | [ [DatasetMetadataBuiltInFieldResponse](#datasetmetadatabuiltinfieldresponse) ] | | Yes |
|
||||
|
||||
#### DatasetMetadataListItemResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| count | integer | | No |
|
||||
| id | string | | Yes |
|
||||
| name | string | | Yes |
|
||||
| type | string | | Yes |
|
||||
|
||||
#### DatasetMetadataListResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| built_in_field_enabled | boolean | | Yes |
|
||||
| doc_metadata | [ [DatasetMetadataListItemResponse](#datasetmetadatalistitemresponse) ] | | Yes |
|
||||
|
||||
#### DatasetMetadataResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| id | string | | Yes |
|
||||
| name | string | | Yes |
|
||||
| type | string | | Yes |
|
||||
|
||||
#### DatasetPermissionEnum
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
|
||||
@@ -877,7 +877,7 @@ Update metadata for multiple documents
|
||||
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Documents metadata updated successfully | [SimpleResultResponse](#simpleresultresponse) |
|
||||
| 200 | Documents metadata updated successfully | [DatasetMetadataActionResponse](#datasetmetadataactionresponse) |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
| 404 | Dataset not found | |
|
||||
|
||||
@@ -1378,11 +1378,11 @@ Get all metadata for a dataset
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Metadata retrieved successfully |
|
||||
| 401 | Unauthorized - invalid API token |
|
||||
| 404 | Dataset not found |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Metadata retrieved successfully | [DatasetMetadataListResponse](#datasetmetadatalistresponse) |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
| 404 | Dataset not found | |
|
||||
|
||||
#### POST
|
||||
##### Summary
|
||||
@@ -1402,11 +1402,11 @@ Create metadata for a dataset
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 201 | Metadata created successfully |
|
||||
| 401 | Unauthorized - invalid API token |
|
||||
| 404 | Dataset not found |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 201 | Metadata created successfully | [DatasetMetadataResponse](#datasetmetadataresponse) |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
| 404 | Dataset not found | |
|
||||
|
||||
### /datasets/{dataset_id}/metadata/built-in
|
||||
|
||||
@@ -1427,10 +1427,10 @@ Get all built-in metadata fields
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Built-in fields retrieved successfully |
|
||||
| 401 | Unauthorized - invalid API token |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Built-in fields retrieved successfully | [DatasetMetadataBuiltInFieldsResponse](#datasetmetadatabuiltinfieldsresponse) |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
|
||||
### /datasets/{dataset_id}/metadata/built-in/{action}
|
||||
|
||||
@@ -1454,7 +1454,7 @@ Enable or disable built-in metadata field
|
||||
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Action completed successfully | [SimpleResultResponse](#simpleresultresponse) |
|
||||
| 200 | Action completed successfully | [DatasetMetadataActionResponse](#datasetmetadataactionresponse) |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
| 404 | Dataset not found | |
|
||||
|
||||
@@ -1503,11 +1503,11 @@ Update metadata name
|
||||
|
||||
##### Responses
|
||||
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 200 | Metadata updated successfully |
|
||||
| 401 | Unauthorized - invalid API token |
|
||||
| 404 | Dataset or metadata not found |
|
||||
| Code | Description | Schema |
|
||||
| ---- | ----------- | ------ |
|
||||
| 200 | Metadata updated successfully | [DatasetMetadataResponse](#datasetmetadataresponse) |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
| 404 | Dataset or metadata not found | |
|
||||
|
||||
### /datasets/{dataset_id}/pipeline/datasource-plugins
|
||||
|
||||
@@ -2314,6 +2314,49 @@ Condition detail
|
||||
| page | integer | Page number | No |
|
||||
| tag_ids | [ string ] | Filter by tag IDs | No |
|
||||
|
||||
#### DatasetMetadataActionResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| result | string | | Yes |
|
||||
|
||||
#### DatasetMetadataBuiltInFieldResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| name | string | | Yes |
|
||||
| type | string | | Yes |
|
||||
|
||||
#### DatasetMetadataBuiltInFieldsResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| fields | [ [DatasetMetadataBuiltInFieldResponse](#datasetmetadatabuiltinfieldresponse) ] | | Yes |
|
||||
|
||||
#### DatasetMetadataListItemResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| count | integer | | No |
|
||||
| id | string | | Yes |
|
||||
| name | string | | Yes |
|
||||
| type | string | | Yes |
|
||||
|
||||
#### DatasetMetadataListResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| built_in_field_enabled | boolean | | Yes |
|
||||
| doc_metadata | [ [DatasetMetadataListItemResponse](#datasetmetadatalistitemresponse) ] | | Yes |
|
||||
|
||||
#### DatasetMetadataResponse
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| id | string | | Yes |
|
||||
| name | string | | Yes |
|
||||
| type | string | | Yes |
|
||||
|
||||
#### DatasetPermissionEnum
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
|
||||
Reference in New Issue
Block a user