You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.
View groupJoin the community to find out what other Atlassian users are discussing, debating and creating.
Hello all, can anyone point me in the right direction to return system fields such as summary and description in a Scriptrunner cloud script? I can get custom fields easily enough using this:
def issueKey = "SD-44"
def issue = get('/rest/api/2/issue/' + issueKey)
.header('Content-Type', 'application/json')
.asObject(Map)
.body
def fields = issue.fields as Map
def product = get("/rest/api/2/field")
.asObject(List)
.body
.find {
(it as Map).name == 'Product'
} as Map
def productValue = (fields[product.id] as Map)?.value
return "The value of ${product.name} custom field is: ${productValue}"
however for system fields I have not been able to figure out how to return the values.
Thanks you in advance for your time.
-wade
well this was way easier than i imagined, lol.
def summary = fields.summary did the trick
We often have questions from folks using Jira Service Management about the benefits to using Premium. Check out this video to learn how you can unlock even more value in our Premium plan. &nb...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.