Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Add Insight Object Values to Jira Automation Rule

James Calimutan March 9, 2022

Trying to add object details from Insight to an automation rule but it does not appear I have the right query.

image.png

The rule works but I was hoping to add the asset name and model in the description. I was hoping to add the assigned user to the summary field.

2 answers

1 accepted

1 vote
Answer accepted
Nithaya
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 9, 2022

Hi @James Calimutan ,

I'm Nithaya from the Automation team at Atlassian. Since you used an Insight object trigger, you cannot use the format {{issue.(custom field name).(attribute name)}} because there is no issue triggered in your rule. 

But you can access to the object attributes by using this format:  {{object.(attribute name)}}

In your case, it should look like this: {{object.name}}, {{object.model}}, {{object.user}}

Let me know if it works,

Cheers,

Nithaya.

Mark Segall
Community Champion
March 9, 2022

Disregard my response.  @Nithaya had a sharper eye than me on this one noticing that this is an object update.

Like James Calimutan likes this
James Calimutan March 9, 2022

Thanks Nithaya. 

Need help with the correct attributes to use. The below only pulls up the name of the asset and nothing else. I was hoping to get the Assigned User in the Summary and the Name and Model in the Description. Thanks in advance,

image.png

image.png

Mark Segall
Community Champion
March 9, 2022

Hi @James Calimutan - Without visibility into your schema, you should be using the following values:

{{object.<object type where your reference data is stored (e.g. Users)>.<attribute you're trying to bring in (e.g. Name)}}

Like Nithaya likes this
James Calimutan March 9, 2022

Thanks @Mark Segall - still not there yet. Not sure if I did your recommendation correctly. 

image.pngimage.png

Nithaya
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 9, 2022

Hey @James Calimutan !

Did you manage to display anything? From what I see, the names of your attributes and references start with uppercase letters. I think that smart values are mostly case-sensitives.

Cheers,

Nithaya.

James Calimutan March 9, 2022

Hi @Nithaya

I removed computers from the syntax as that would not return anything. This is the syntax now. I still cannot get the Assigned User field to show up. The result for model is the key and not the actual model not sure why.

image.pngimage.png

Nithaya
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 9, 2022

I see! Since the attribute "Model" is an object reference, you need to use: {{object.Model.(the attribute name to get the model name)}}

As for the attribute "Assigned user", you need to type {{object.Assigned User}} with the space in between.

Let me know if it works!

Cheers,

Nithaya.

James Calimutan March 9, 2022

Success! Got it using the syntax below. Thanks @Nithaya and @Mark Segall for all your help!

image.png

Like Nithaya likes this
0 votes
Mark Segall
Community Champion
March 9, 2022

Hi @James Calimutan 

This should be possible.  The smart value format should look something like this:

{{issue.customfield_xxxxx.attribute}}
Ex. {{issue.customfield_12345.name}}

If you're dealing with scenarios where the object is referencing another object type it would look something like this:

{{issue.customfield_xxxxx.referenceAttribute.attribute}}
Ex. {{issue.customfield_12345.asset.name}}

 Hope this helps.

James Calimutan March 9, 2022

Thank you Mark!

Suggest an answer

Log in or Sign up to answer