Skip to content

Unified Catalog Entity Modification



POST /api/v1/unified_catalog/entity/modify

Overview

Modify a unified catalog entity.

Body Request Parameters

Parameter Name Type Required Description
urn string Entity URN. It is recommended to pass this to precisely locate the modification target.
Allow empty: False
entityType string Y Entity type code.
Allow empty: False
name string Y Entity name.
Allow empty: False
attributes json Entity attributes object.
Allow empty: False
telemetrySelectors array Associated query information configuration.
Allow empty: False

Parameter Supplementary Description

Request Parameter Description

Parameter Name type Required Description
urn string No Entity URN. It is recommended to pass this to precisely locate the entity.
entityType string Yes Entity type code.
name string Yes Entity name.
attributes json No Entity attributes object to be updated.
telemetrySelectors array No Entity associated query configuration to be updated.

Relationship Field Usage Instructions

  • attributes.depends_on will be written as links.
  • attributes.component_of will be written as contains.
  • To clear relationships, explicitly pass an empty array, e.g., {"component_of":[]}.

Calling Notes

  • It is recommended to pass urn, entityType, and name simultaneously.
  • Upon successful modification, the target entity's urn is returned.
  • If a new tag name is passed in the tag field, the corresponding tag will also be automatically created.

Request Example

curl 'https://openapi.truewatch.com/api/v1/unified_catalog/entity/modify' \
-H 'DF-API-KEY: <DF-API-KEY>' \
-H 'Content-Type: application/json;charset=UTF-8' \
--data-raw '{"urn":"urn:mysql:default:demo","entityType":"database","name":"demo","attributes":{"project":"demo","env":"test","component_of":[]}}'

Response

{
    "code": 200,
    "content": {
        "urn": "urn:mysql:default:demo"
    },
    "errorCode": "",
    "message": "",
    "success": true,
    "traceId": "TRACE-XXXX"
}