Forums

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

Get ticket key from PDF email attachment?

Amy Biasella
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.
September 25, 2019

Short version: Is there a way for Jira mail handlers to scan PDF attachments for a ticket key so it can post a comment on that ticket? (like how Jira scans subject lines for existing ticket keys)

Long version: We have a JWT post function on a workflow that sends an email to an external vendor (Business X) with a subject containing the ticket key where the transition took place. Business X auto-logs this email in their system (Salesforce). At the end of their process, an employee logs work, which sends a return email with a PDF to our Jira (our default Jira email is the 'user' that logs the ticket in their system). Of course, their return subject line contains information relevant to their system, not ours. So they do not include the original key in their subject by default. This just creates extraneous new issues in our Jira project. But their PDF attachment does contain the issue key. Is there anything we can do in our Jira instance to attach these incoming emails to the correct ticket? The external vendor does not seem committed to changing their outgoing email settings so I'm investigating what we could do.

2 answers

0 votes
jira guy
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.
September 25, 2019

@Zoi Raskou 

Automation for jira cannot read the attachment. It can only check if there are any attachments. 

 

@Amy Biasella You can may be try using smart attachments which indexes attachments and allows to search inside attachments

https://marketplace.atlassian.com/apps/1211135/search-attachments?hosting=server&tab=overview

Zoi Raskou
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.
September 26, 2019

Good to know, thanks. I haven't used Automation for Jira for this purpose so I was only assuming!

Amy Biasella
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.
September 26, 2019

'Search attachments' (different than smart attachments, which we also use) looks like it only indexes attachments once they're already in an issue. I want to do some sort of pre-issue creation searching. 

0 votes
Zoi Raskou
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.
September 25, 2019

Hello Amy, 

If you are using Scriptrunner you can. Provided that the issue key is in the title then you can grab it (getAttachments(Issue issue)). 

If you are not, then it's possible that Automation for Jira covers this scenario (https://marketplace.atlassian.com/apps/1215460/automation-for-jira).

Amy Biasella
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.
September 25, 2019

The key is not in the attachment title either, unfortunately.

Suggest an answer

Log in or Sign up to answer