Automated Salesforce File Archiving and Cleanup Workflow

somdn_product_page

This n8n workflow automates the process of managing old Salesforce ContentDocuments by archiving and deleting older files to optimize storage and maintain data hygiene. The process begins with a scheduled trigger, which initiates the workflow periodically. It retrieves all Salesforce ContentDocuments older than one year and processes each file in batches. The workflow downloads each file’s content via HTTP requests, then uploads the files to Amazon S3 for long-term storage. It creates corresponding Salesforce records for the uploaded files and prepares ContentDocument IDs for deletion. To avoid deleting user attachments, it filters out such files before deletion. Finally, it deletes the original files from Salesforce and sends notifications via Slack to keep relevant teams informed about the progress. This automation is particularly useful for organizations looking to efficiently manage Salesforce storage by archiving old files and eliminating unnecessary data while ensuring team awareness through Slack updates.

Node Count

>20 Nodes

Nodes Used

awsS3, code, httpRequest, salesforce, scheduleTrigger, slack, splitInBatches, stickyNote

Reviews

There are no reviews yet.

Be the first to review “Automated Salesforce File Archiving and Cleanup Workflow”

Your email address will not be published. Required fields are marked *