mirror of
https://github.com/langgenius/dify.git
synced 2026-11-13 14:51:39 +08:00
fix(api): bind dataset operations to owners (#40149)
This commit is contained in:
1 parent
bee269afe8
commit
ef8544b173
35 files changed
+1520
-496
No files matched your search
@@ -5975,6 +5975,7 @@ then asynchronously generates summary indexes for the provided documents.
|
||||
| Code | Description |
|
||||
| ---- | ----------- |
|
||||
| 204 | Documents metadata updated successfully |
|
||||
| 404 | Dataset, document, or metadata not found |
|
||||
|
||||
### [PATCH] /datasets/{dataset_id}/documents/status/{action}/batch
|
||||
#### Parameters
|
||||
@@ -17507,7 +17508,7 @@ Request payload for bulk downloading documents as a zip archive.
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| document_id | string | Document ID whose metadata should be updated. | Yes |
|
||||
| document_id | string (uuid) | Document ID whose metadata should be updated. | Yes |
|
||||
| metadata_list | [ [MetadataDetail](#metadatadetail) ] | Metadata fields to update. | Yes |
|
||||
| partial_update | boolean | Whether to partially update metadata, keeping existing values for unspecified fields. | No |
|
||||
|
||||
@@ -19304,7 +19305,7 @@ Enum class for large language model mode.
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| id | string | Metadata field ID. | Yes |
|
||||
| id | string (uuid) | Metadata field ID. | Yes |
|
||||
| name | string | Metadata field name. | Yes |
|
||||
| value | string<br>integer<br>number | Metadata value. Can be a string, number, or `null`. | No |
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ User-scoped operations
|
||||
| mode | query | App types the ``app`` usage face (``get app``) lists and filters. A curated subset of :class:`AppMode`: the real, user-facing app categories. Excludes runtime-only mode tags that are not standalone apps (``rag-pipeline`` is a knowledge ``Pipeline``; ``channel`` is unused) and the roster-owned ``agent`` type (surfaced through the roster, not this list). Members reference ``AppMode.*.value`` so the subset relationship is type-checked: dropping a member from ``AppMode`` breaks this at import. This is the single source for the listable set — params, filters, and the generated CLI whitelist all derive from it. | No | string, <br>**Available values:** "advanced-chat", "agent-chat", "chat", "completion", "workflow" |
|
||||
| name | query | | No | string |
|
||||
| page | query | | No | integer, <br>**Default:** 1 |
|
||||
| workspace_id | query | | Yes | string |
|
||||
| workspace_id | query | | Yes | string (uuid) |
|
||||
|
||||
#### Responses
|
||||
|
||||
@@ -129,7 +129,7 @@ User-scoped operations
|
||||
| Name | Located in | Description | Required | Schema |
|
||||
| ---- | ---------- | ----------- | -------- | ------ |
|
||||
| include_secret | query | Include encrypted secret values in the exported DSL | No | boolean |
|
||||
| workflow_id | query | Export a specific workflow version instead of the current draft | No | string |
|
||||
| workflow_id | query | Export a specific workflow version instead of the current draft | No | string (uuid) |
|
||||
| app_id | path | | Yes | string |
|
||||
|
||||
#### Responses
|
||||
@@ -600,7 +600,7 @@ mode is a closed enum of listable app types.
|
||||
| mode | [SupportedAppType](#supportedapptype) | | No |
|
||||
| name | string | | No |
|
||||
| page | integer, <br>**Default:** 1 | | No |
|
||||
| workspace_id | string | | Yes |
|
||||
| workspace_id | string (uuid) | | Yes |
|
||||
|
||||
#### AppListResponse
|
||||
|
||||
|
||||
@@ -1539,7 +1539,7 @@ Update metadata values for multiple documents at once. Each document in the requ
|
||||
| 200 | Document metadata updated successfully. | **application/json**: [DatasetMetadataActionResponse](#datasetmetadataactionresponse)<br> |
|
||||
| 401 | Unauthorized - invalid API token | |
|
||||
| 403 | Forbidden - dataset API access or workspace access denied | |
|
||||
| 404 | Dataset not found | |
|
||||
| 404 | Dataset, document, or metadata not found | |
|
||||
|
||||
### [GET] /datasets/{dataset_id}/metadata
|
||||
**List Metadata Fields**
|
||||
@@ -3000,7 +3000,7 @@ Request payload for bulk downloading documents as a zip archive.
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| document_id | string | Document ID whose metadata should be updated. | Yes |
|
||||
| document_id | string (uuid) | Document ID whose metadata should be updated. | Yes |
|
||||
| metadata_list | [ [MetadataDetail](#metadatadetail) ] | Metadata fields to update. | Yes |
|
||||
| partial_update | boolean | Whether to partially update metadata, keeping existing values for unspecified fields. | No |
|
||||
|
||||
@@ -3513,7 +3513,7 @@ Model class for i18n object.
|
||||
|
||||
| Name | Type | Description | Required |
|
||||
| ---- | ---- | ----------- | -------- |
|
||||
| id | string | Metadata field ID. | Yes |
|
||||
| id | string (uuid) | Metadata field ID. | Yes |
|
||||
| name | string | Metadata field name. | Yes |
|
||||
| value | string<br>integer<br>number | Metadata value. Can be a string, number, or `null`. | No |
|
||||
|
||||
|
||||
Reference in new issue
Block a user