Home > Forum > Database > What is /api/nav/db/1/attachments/4/preview?hash=0?

What is /api/nav/db/1/attachments/4/preview?hash=0?
0

Hi tehre,
quick question:

Somewhere in my notes I saw this string but I can't recall what it points to:

/api/nav/db/1/attachments/4/preview?hash=0

In other words, I seem to remember that at some point this link displayed a preview image that was uploaded somewhere.
But I don't know by which means an attachment was uploaded to this path.

Right now, calling this link throws:

{"type":"https://tools.ietf.org/html/rfc7231#section-6.5.4","title":"Not Found","status":404,"traceId":"00-2cd9a0ba20c4ac24d08366237b7ec881-1e6a399ca0898779-00"}

Can anybody shed light on this?

Thanks!

In reply to: Daniel Krüger (Cosmo Consult)

Hi Florian,

4 refers to the Id of the attachment in your database. It may have been deleted and therefore the URL returns a 404 / Not found.
If you open the developer tools and click on an attachment, you will notice this URL in the networking tab.

Best regards,
Daniel

Hey Daniel,

thanks, makes sense.
With

SELECT ATT_ID, ATT_WFDID
FROM WFDataAttachmets

I found all attachments and using ATT_ID, e.g. 2 in the url /attachments/2/preview?hash=0 shows the preview image.

Now, is there a suggested way to delete specific attachments without deleting the instance? ATT_WFDID provides the ID to the element url.
However, the attachments panel doesn't allow manualy deletion it seems.