How can I attach a document to an issue through Automation?

Andrew May 15, 2023

Let me give you an example of what I'm trying to do.

If a task needs to go through Security, I'd like to create a sub-task titled "Security Paperwork" and attach the PDF form to the issue.

I have no problem using Automation to generate the sub-task after the appropriate requirements have been reached, with the appropriate title.

I cannot figure out how to attach the PDF form to the sub-task. I would like to just drag the PDF to that "Copy Attachment from Current issue" chiclet, but that's not an option.

Untitled.png

2 answers

2 accepted

4 votes
Answer accepted
Kristján Geir Mathiesen
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 15, 2023

Hi @Andrew and...

giphy

I believe you cannot with JSM OOTB GUI feature.

However, you can add an attachment via the REST API. See the answers on this question.

HTH,
KGM

Andrew May 16, 2023

hahaha! I'm glad you've got a sense of humor.
But you've used too many acronyms for me to understand what you're saying. :(

Like # people like this
Kristján Geir Mathiesen
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 1, 2023

Sorry @Andrew 

OOTB = out of the box
JSM = Jira Service Mangement
GUI = graphical user interface

I believe you cannot with Jira Service Mangement out of the box with a graphical user interface.

Best, KGM

3 votes
Answer accepted
Steve Long -Evelon-
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 15, 2023

Hi @Andrew

So currently, Jira Automation doesn't support adding attachments. Aka there's nowhere in this UI where you can upload an attachment to be added to newly created tickets - there's an open feature request for this.

Couple of things that are maybe worth thinking about though:

1. You can use the Jira REST API to add attachments to tickets.

2. You can copy attachments from related tickets as per your screenshot - so in theory if all of these newly created tickets had a common Parent/Epic (established via another automation rule maybe), they could be copied across.

Hope that helps - Steve.

Andrew May 16, 2023

Thanks, Steve.

I think your confidence is misplaced: I don't think I can use the JIRA REST API.

A combination of "I don't own the server it's deployed to" (our IT won't give me access) and "I'm not comfortable using a REST API".

Should I just make a "Shell" epic, from which all new Epics can inherit attachments from? And then can I hide it so nobody else sees the sin happening in the background? I'm not sure how I would get that to work...

Tyler Frederick October 15, 2023

Not a direct answer to your question, but perhaps it will be helpful to you or someone else. This is the opposite of what you're trying to do, one-way sync new attachments from one issue to another. I would think your approach of using a "shell"/template issue would work just fine.

image.png

Suggest an answer

Log in or Sign up to answer