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

Automation: Slack message formatting for multiline comments

Roman Pankovski June 22, 2022

Hi everyone!

I need little advice with visual for Slack messages sent with Automation.

1. This is Rule

CleanShot 2022-06-22 at 15.24.18.jpg

2. Some detail of Slack message

CleanShot 2022-06-22 at 15.26.38.jpg

3. What in Jira issue comment

CleanShot 2022-06-22 at 15.27.57.jpg

4. What I receive in Slack channel

CleanShot 2022-06-22 at 15.29.19.jpg

I marked line with applied block quote formatting.

I used official source for this: Quotes, inline code blocks, lists 

Used smart-value: 

>{{issue.comments.last.body.abbreviate(300)}}

My question:

How can I make the entire comment WITH multiline be formatted with block quote with {{issue.comments.last.body.something-here}}???


Thnx in advance!!!


For clarification: I know how to send all needed info with JSON Payload :)  I just wonder about solving this specific question. Maybe anyone already faced the same and found solution?

1 answer

1 accepted

2 votes
Answer accepted
Daniel Eads
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 27, 2022

Hi @Roman Pankovski ,

One possibility (if you don't care too much about having text after the comment) is using the '>>>' syntax to tell Slack that everything after that point is part of a quote. For example, if the "issue was returned" message you have could be moved up, this might fit your needs:

*Issue was returned to previous Assignee for review.*

Reasons:
>>>{{issue.comments.last.body.abbreviate(300)}}

Unfortunately there doesn't seem to be a way to tell Slack when a quote like that ends - it just goes until the message is completed. This is a bit of a difference from things like code blocks where the ``` characters can both start and end a code block.

Cheers,
Daniel

Roman Pankovski July 1, 2022

Thnx a lot, Daniel!

I will test this syntax!

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