Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,363,069
Community Members
 
Community Events
168
Community Groups

Cannot set User-type attribute using REST API

Rei Song I'm New Here Sep 16, 2022

I am following the formatting of the JSON as shown on this guide, but I keep getting the following error:

 

{"errorMessages":[],"errors":{"rlabs-insight-attribute-55":"<Account Id> is not valid Object id or key"}}

 

Here is the payload I'm submitting for https://api.atlassian.com/jsm/insight/workspace/<workplace ID>/v1/object/create endpoint:

 

{
"objectTypeId": "2",
"attributes": [
{
"objectTypeAttributeId": "14",
"objectAttributeValues": [
{
"value": "Blahblahblah"
}
]
},
{
"objectTypeAttributeId": "55",
"objectAttributeValues": [
{
"value": "<Account Id>"
}
]
}
]
}

55 is the ID of the User-type attribute. I'm passing in the Atlassian ID (not the username/email address) as shown in the doc.

1 answer

0 votes
Rei Song I'm New Here Sep 16, 2022

Never mind.. I realized I set the attribute type to an another Insight object (User list). I had to punch in the asset key instead of account ID and it worked.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Site Admin
TAGS

Atlassian Community Events