tayganr / purviewcli

Microsoft Purview CLI
https://aka.ms/purviewcli
MIT License
47 stars 27 forks source link

Issue for updating businessmetadata for entity #25

Open yifan-zhou922 opened 4 months ago

yifan-zhou922 commented 4 months ago

Payload bug for calling POST atlas/v2/entity/guid/{guid}/businessmetadata The cli tool will call the service API with the following wrong payload

{
  "entity": {
    "businessAttributes": {
      "businessMetadataGroupExample": {
        "businessMetadataAttributeExample1": [
          "1"
        ],
        "businessMetadataAttributeExample2": "5"
      }
    }
  }
}

while the correct payload should be

{
 "businessMetadataGroupExample": {
        "businessMetadataAttributeExample1": [
          "1"
        ],
        "businessMetadataAttributeExample2": "5"
      }
} 

More details for this API https://learn.microsoft.com/en-us/rest/api/purview/datamapdataplane/entity/add-or-update-business-metadata?view=rest-purview-datamapdataplane-2023-09-01&tabs=HTTP

Customers reported that they have used the correct payload however getting the error.

yifan-zhou922 commented 4 months ago

Please feel free to close the issue if it is a false alarm report. Thanks.