Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

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,560,577
Community Members
 
Community Events
185
Community Groups

jira automation accessing project properties

Hello,

Is it possible with a jira automation rule to get a jira project property?  You specify the project property key and you get the project property value. I already searched in the available smart values but didn't find anything.

Thanks

4 answers

2 accepted

0 votes
Answer accepted
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2022

Hi @Luc Noppen 

You can read the entity properties, as is shown here for issues: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/#--issue.properties--

For a project property, it would be:

{{project.properties."myPropertyName"}}

The key is context...if the trigger is for a project, use above.  If instead it is for an issue you might need to explicitly call the REST API from a web request in the rule to get the project to access the properties.  Before trying that, perhaps first try {{issue.project.properties."myPropertyName"}} to see if they are available.

Kind regards,
Bill

Hello,

I'll test this before accepting the answer.

Thanks for your reply.

Kind regards

Like Bill Sheboy likes this
0 votes
Answer accepted
Alberto Salvante
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2022

Hi Luc,

what do you mean to get the jira property? What is your purpose?

If you mean to edit the property in automation there is a specific section to do that.

Screenshot 2022-05-24 at 10.37.59.png

Hope it helps.

Best,
Alberto

0 votes
Mykenna Cepek
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Jan 19, 2023

I know this answer is tagged for Cloud, but I could use the answer for Data Center. I've tried both:

{{project.properties.snji-comments}}

{{project.legacyProperties.snji-comments}}

The value is set, as I can retrieve it with:

https://jira.company.com/rest/api/2/project/PROJ/properties/snji-comments 
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
Jan 19, 2023

Hi @Mykenna Cepek 

I am using Jira Cloud, not Server/Data Center, and...I wonder if you can find an issue in the project and access the properties that way with:

{{issue.project.properties.snji-comments}}

My understanding is the {{project}} smart value only works with the project-based triggers so perhaps that's why the smart value doesn't work for Server/Data Center version.

Kind regards,
Bill

Mykenna Cepek
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Jan 26, 2023

Bingo! @Bill Sheboy to the rescue!

I changed the rule from using a Scheduled (project-less) trigger to using a Manual trigger, which put the execution in the context of a specific issue (and project).

Bill's smart value worked, as did one of my original guesses, as shown below.

 

ReadEntityProperty.png

Since this is a single-project (not Global) rule, one might reasonably wish that the project.properties... smart value would resolve to the only project that the rule is scoped to.

Like Bill Sheboy likes this

Hello,

With your answer I'm able to set a project property and with the answer of Bill Sheboy I'm able to read the project property.

Your answers combined give me what I need.

Thanks.

Suggest an answer

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

Atlassian Community Events