Insight Customer Jira field lookup and selection using automation

Rob August 11, 2021

Hello Jira community!

I am in need of some help. I have looked through many other posts dealing a lot with groovy scripting and a good chunk of it is over my head, so trying the blunt approach.

I have my insight jira fields all setup and they work just fine. I have a project that is integrated with a 3rd party tool that automatically creates tickets for me. There is a free text field (as most of the fields are in this project) that contains the name of a server. I would like either some kind of post function or some kind of automation I can kick off (either manually or on a scheduled bases) that would take the server name in that free text field, search for and find the Insight object (of the same name) and then populate it in my insight custom jira field that I have added to the same screen/project.

I have no control over the 3rd party plugin that allows for the ticket creation, so I can't have it automatically find it for me from that end.

I am guessing I need some kind of groovy script to accomplish this, but don't really know which ones to look at to be honest.

Thank you all in advance!

1 answer

1 accepted

1 vote
Answer accepted
Peter-Dave Sheehan
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 12, 2021

You might not need any scripting.

In your Create transition, add a post function.

Select "insight post function"

Choose "Assign Objects from an IQL query based on data from an issue"

You can leave the condition blank or set it to "true"

In IQL, put something like this

objectType = Servers and Name=${Name of Jira Field with server name}

Then select the correct insight field in the target custom field selector.

If your custom field contains other text than just the Server Name, then yeah, you'll need some more complex scripting to extract just the name, find the matching object and set the value of the custom field.

But otherwise, this is the simplest approach

Rob August 16, 2021

Thank you @Peter-Dave Sheehan

I never thought to look at the post function section. I had just assumed I needed to do it through the project automation somehow.

This has worked out perfectly!

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events