This all in Cloud.
We have ITSM and software issues linked, on occassion.
When that happens, if a new attachment is added to the ITSM ticket, I need to copy it to the software ticket.
Only that one. Only the new one. And I can NOT delete the attachments that already exist in software.
I've been looking around, and people say you can get a download URL from the rest api using scriptrunner, then use the data you can get from that URL to create the attachment in the other ticket also via API.
Problem is, none of these seem possible?
When I grab attachment data via rest api, I don't get the URL to the attachment, or the content in binary/raw form. I get a crapload of metadata, but that's about it.
Also, if my listener script is triggered by the attachment creation, I can't see how I can get issue data, so I can look for the linked issues, to know where to copy it. It's not directly available and I can't seem to get it from the attachment metadata.
I'm honestly out of ideas here. Please help.