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

Is there a way to identify whether an attachment is visible on a page?

Henry Edwards April 7, 2022

I'm aiming to delete duplicated attachments from a Confluence instance using the rest API. There are multiple duplicated files which are attached to pages but not visible on the page, and not being used, hence we're looking to delete them.

 

Is there a field which can be used with the rest API to identify attachments which are attached to a page but don't appear on it?

1 answer

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 7, 2022

Welcome to the Atlassian Community!

All attachments are visible on a page, if the person looking has permission to see the page.

I think you mean "does the page include a 'show attachment' macro/function so the attachment is partially or fully rendered when viewing the page".  

It is a technical quibble on the wording, but it is important because the answer to "is an attachment visible on a page" is simply "yes". 

I think the answer you are looking for is "not easily".  You would need to search all of your page content for the macros that make attachments render on the page, and bear in mind that a most of those macros do not limit themselves to "file attached to the current page" - most can draw in attachments from other pages.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events