The URL pattern for having a particular attachment opened such that someone could comment on it is as follows:
https://airtable.com/table_ID/view_ID (optionally)/record_ID/field_ID/attachment_ID
As far as I know, the only way you’d be able to get both the field ID and the attachment ID is with a script. Since you’re already using an Automation, assuming your base is on a Pro Workspace, this isn’t a hinderance:
Before the automation step you have now, add a Run a script
action step that has two input variables (add input variables on the left side of the screen): recordURL
which should be the trigger record’s URL, and attachmentIds
which should be the value from the attachment field as a “List of… ID” (as opposed to a list of URLs or list of names).
Then add the following script (renaming the Attachment field as necessary):
let {recordURL, attachmentIds} = input.config()
let attachmentFieldName = "Attachments"
let recordInfo = {
tableId: recordURL.split("/")[3],
}
let fieldID = base.getTable(recordInfo.tableId).getField(attachmentFieldName).id
let constructedURLs = attachmentIds.map(id => {
return recordURL + "/" + fieldID + "/" + id
})
output.set("constructedURLs", constructedURLs)
Use the output of the script in your message to collaborators