Forums

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

How to display list of items which have Blocked label

Елена Елена
Contributor
March 13, 2023

Hi all

I want to get list of blocked items. But we use Blocked label for this purpose.

I used this article to create the rule - https://community.atlassian.com/t5/Automation-articles/Send-a-list-of-issues-in-Slack-with-Jira-automation-s-newest/ba-p/1411819

In Audit log I got success status, but the issues list doesn't appear in Slack

104311.png

I got only "Hey we have following issues to be blocked"

How could I change Slack message?

Thanks

1 answer

1 accepted

1 vote
Answer accepted
Ash Yadav
Community Champion
March 13, 2023

Hi @Елена Елена , 

 

While it appears that the automation worked successfully and identified the correct issues, I believe there might be some error in the web-hook part of your automation. 

 

Can you please attach a screenshot of your And: Send Slack Message action? 

Please blur or censor the web-hook URL (just make sure its correct).

And the incoming message you're receiving on Slack. 

 

Out of curiosity, can you attach any link to the Slack message as a troubleshooting step? Just in case its getting filtered etc. 

 

Looking forward to hearing from you. 

 

Kind Regards, 

Ash 

Елена Елена
Contributor
March 13, 2023

123329.png

the message in Slack - "Hey we have following issues to be blocked" and nothing more

Ash Yadav
Community Champion
March 13, 2023

Can you replace your message with the following: 


www.google.com

Hey, we have the following issues to be blocked:

{{#lookupIssues}} *<{{url}}|{{key}}> {{/}}

 


The google URL is used to check If hyperlinks are being filtered in your message, in which case the issue is with your Slack configuration rather than the automation. 

 

Let me know how you get on and please post the output after the automation is run. 

Kind Regards, 

Ash 

Елена Елена
Contributor
March 13, 2023

154156.png

How to display issue from new line?

Like Ash Yadav likes this
Ash Yadav
Community Champion
March 13, 2023

Hi @Елена Елена looks like that worked :) 

 

So your correct message should be: 


Hey, we have the following issues to be blocked:

{{#lookupIssues}} *<{{url}}|{{key}}> {{/}}


As for new lines, I'm not sure that is going to be possible but I could be wrong. 

A quick search netted me the following discussion: 

https://community.atlassian.com/t5/Jira-Software-questions/Jira-automation-insert-new-line-into-the-audit-log/qaq-p/1714479

 

I would also explore this article from Slack regarding text formatting for messages sent to Slack via APIs:

https://api.slack.com/reference/surfaces/formatting

 

I think we got the initial issue resolved so I'm going to leave the rest to you. 

 

Kind Regards, 

 

Ash 

Елена Елена
Contributor
March 13, 2023

Yes, I did it.

One more question how to put project name into the text

Hey, <project.name> has the following issues to be blocked:

I tried {{project.name}} it displays nothing

160947.png

Ash Yadav
Community Champion
March 13, 2023

Can you try this:


Hey, <{{project.name}}> {{/}} has the following issues to be blocked:

{{#lookupIssues}} *<{{url}}|{{key}}> {{/}}


I'm not on a computer at the moment to test it but this should be a good place to start. 

Also see: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-projects/

 

Hope it helps.

 

Kind Regards,

 

Ash 

Елена Елена
Contributor
March 13, 2023

Thanks, but none of them works

Елена Елена
Contributor
March 13, 2023

To make new line the message should the following

Hey, we have the following issues to be blocked:

{{#lookupIssues}} *<{{url}}|{{key}}> 

{{/}}

Like Ash Yadav likes this
Елена Елена
Contributor
March 15, 2023

One more question to finish this topic

Can I sort issues by Sprint, for example stories from current on the top.

095725.png

Ash Yadav
Community Champion
March 15, 2023

Suggest an answer

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

Atlassian Community Events