Include a custom "user picker" field's data in a Slack message using Automation

Stephanie Willis September 17, 2020

I have a custom "user picker" field. I'm setting up an automation between JIRA and Slack that fires a custom message into a Slack channel when a ticket hits certain criteria. One piece of information I'd like to show in the Slack channel is the user selected on that field. 

 

I've added this to the Slack message that send: 

*Incident Commander:* {{issue.customfield_12066}}

 

but what appears is this: 

Incident Commander: 557058:41a2c14d-63c1-4cf6-94ba-7a22df13d6bb

 

How do I get the name to render?

2 answers

1 accepted

2 votes
Answer accepted
Stephanie Willis September 17, 2020

I actually solved this one on my own shortly after posting this. I added .displayName to the end of the query: 

 

*Incident Commander:* {{issue.customfield_12066.displayName}}
0 votes
Daniel Eads
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 12, 2020

Hi Stephanie,

Glad you were able to get the smart value working to show displayName in your Slack message!

If it's useful, we've recently put out a script that can sync Slack IDs with Jira properties - making it possible to at-mention Slack users in your Automation messages. If you're spinning up new channels for incidents, the at-mention might help get the right people in the channel faster. Or it could be useful to add more context in Slack itself if someone isn't familiar with the incident commander's name at a glance. At any rate, instructions and the script are available here.

Cheers,
Daniel | Atlassian Support

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events