You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
I need to set a field a custom field in Jira issue. This field has Insight type and is a single selection.
I tried to search community and Insight documentation but they are outdated and misleading, so this is what I found. In the end I will show you the way to find answers yourself.
Field: customfield_14472
Issue: ADM-262
Object Key: AR-8155
As usual, add Edit Issue fields action, do not select field in Choose fields to select.
Copy paste the following text into Additional fields section (under more options)
{
"fields": {
"customfield_14472": [{
"workspaceId": "e02eca9b-beba-4406-bcbc-6c95dcb24212",
"id": "e02eca9b-beba-4406-bcbc-6c95dcb24212:8155",
"objectId": "8155"
}]
}
}
What is workspaceId? It is your Insight database id. There is no easy way to find it, if you know it please tell me in comments. This is how I discovered it.
1. Prepare a test ticket, say ADM-262
2. Find the field and set a known value to it. E.g. Customer Name
3. Go to your Insight database and find the customer. Recall the Key of the object, say AR-8155
4. Copypaste this url to you browser
https://<your company>.atlassian.net/rest/api/latest/issue/ADM-262
The page will show you large json with plenty of info. Press Ctrl+F and find your customer Key, in my case it is 8155.
"customfield_14472":[{"workspaceId":"e02eca9b-beba-4406-bcbc-6c95dcb24212","id":"e02eca9b-beba-4406-bcbc-6c95dcb24212:8155","objectId":"8155"}]
Now you can just copy this selected text into Automation and replace 8155 with whatever you receive from your rule.
This receipt works pretty much with every field type in Jira - setup it, create a test issue, set the field and receive internal representation through REST API. Then use it for automation.
I hope it helps!