Skip to content

Commit

Permalink
Add checker end point (#1316)
Browse files Browse the repository at this point in the history
* Add checker end point
  • Loading branch information
gonchik authored Feb 2, 2024
1 parent a100d4f commit 1cd9f34
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions atlassian/insight.py
Original file line number Diff line number Diff line change
Expand Up @@ -656,3 +656,23 @@ def update_issue_insight_field(self, key, field_id, insight_keys, add=False):
}
data = {"fields": {field_id: [{"key": i} for i in insight_keys]}}
return self.put("{base_url}/{key}".format(base_url=base_url, key=key), data=data)

def check_duplicate_attribute_values(self):
"""
Check for duplicate attribute values in Insight objects with cardinality maximum 1
used for Data Center
link: https://confluence.atlassian.com/jirakb/duplicated-attribute-values-in-insight-objects-with-cardinality-maximum-1-1114816155.html
:return:
"""
url = "rest/insight/1.0/health/consistency/duplicates/attributevalues"
return self.get(url)

def delete_duplicate_attribute_values(self):
"""
Delete duplicate attribute values in Insight objects with cardinality maximum 1
used for Data Center
link: https://confluence.atlassian.com/jirakb/duplicated-attribute-values-in-insight-objects-with-cardinality-maximum-1-1114816155.html
:return:
"""
url = "rest/insight/1.0/health/consistency/duplicates/attributevalues"
return self.delete(url)

0 comments on commit 1cd9f34

Please sign in to comment.