Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

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

Delete unwanted attachements based on file size

Sam Oppewal
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 14, 2025

Hello,

We are using Jira Service Management, specifically with the Email channel for the creation of tickets. The issue we are running into is that all images for the email signature end up in the attachments. I already have set up a signature filter so these are collapsed by default, but they still end up in the attachments. I found this thread as a solution:

https://confluence.atlassian.com/jirakb/delete-unwanted-attachments-from-jsm-requests-using-automation-1235853531.html

This seems to be perfect, except for one detail. All attachments always get a sequential name; i.e., Image001.png, Image002.png, etc. Some of these images are a screenshot of a reported issue, so I cannot delete those.

The solution I came up with is deleting attachments based on their file size, as all images for the signature are under 15kb. A screenshot will always be bigger. This lands me on the {{issue.attachment.[xxx].size}} smart value, but I cannot get this to work, as it would have to scan and process every image individually when an issue is created, and when a comment gets added.

How would I go about this? Is this even possible, or does someone have a better solution?

1 answer

0 votes
Jack Brickey
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 14, 2025

Hi @Sam Oppewal , I recall that email signatures were a mess in the past (reference JSDCLOUD-5878 ) but thought it was addressed. Did you follow the instructions here - change-how-emails-are-processed-across-service-projects

Sam Oppewal
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 14, 2025

Hi @Jack Brickey , thanks for the quick response. I've check the setting for this, and they are set like this:

  • Strip Quotes: Set to strip them
  • HTML parsing: Enabled
  • Hide email signatures: 
    • Use default detection to hide: Enabled
    • Use customer text to detect and hide: Enabled, with two Customer rules 
      •  Met vriendelijke groet,
      • With kind regards,
  • DMARC is also Enabled.

As far as I know, these are the settings to use for the import. Would you suggest otherwise based on my request above? 

To be clear about the question: It is colapsing the signatures, but the attachements are poluting the entire tickets, which makes them very time consuming and confusing to work with.

Thanks in advanced!

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events