Metadata

Update Metadata Field

Rename a custom metadata field.

patch/datasets/{dataset_id}/metadata/{metadata_id}

Request

  • Base URL
    https://api.dify.ai/v1
  • URL
    https://api.dify.ai/v1/datasets/{dataset_id}/metadata/{metadata_id}
  • Auth
    HTTP bearer

Path parameters

dataset_idstring uuid required

Knowledge base ID, from List Knowledge Bases. For a scoped key, copy the ID from the Dify URL.

metadata_idstring uuid required

ID of the metadata field to rename. See List Metadata Fields.

Request body

namestring required

New name for the field. Must be unique among the knowledge base's fields and at most 255 characters.

Response

Metadata field updated successfully.

idstring

Metadata field identifier.

namestring

Metadata field name.

typestring

Metadata field type.

Changes

No recorded changes to this operation across all 17 revisions of this API.