Use Case: Automate Emails with Schedule-Triggered Flow

If you also have the need to send out batch emails under specific criteria or at specific dates, you should definitely consider Schedule-Triggered Flow. Schedule-Triggered Flow can also run for a batch of records if the object and the filter conditions are specified. You build the flow as if it is for one record, but it will run for all the records that match the criteria (So you don’t have to think about collections. Isn’t this nice?!). Let’s dive into how to set this up!

* Big thanks to Parker for sending in the case!

Lulu Mobile uses the standard Account object to track phone subscriptions. They have a field called “Expiration Date” which tracks when the subscription ends. When it reaches 90 days before the expiration date, they want to send a reminder to the customers. They will send it to the primary contact specified on each account.

(Assumption: One account will only have one primary contact)

We will use the Schedule-Triggered flow and let it run daily. Every day we check how many accounts have reached 90 days before the expiration date. Then we send emails to their primary contact.

Since we cannot use formula in the Choose Object and Filter Conditions, we will use a workaround suggested by Salesforce.

Scheduled Action v.s. Schedule-Triggered Flow

“If we schedule the flow to run daily, wouldn’t it exhaust the capacity?” is the question I have about schedule-triggered flow. Because alternatively, we can also schedule actions (ex. in Process Builder) when the expiration date is updated. I imagine this is easier on the workload, as the system evaluates each account only once. However, it might be more error-prone as those actions would need to stay in the backlog for a long time (it is 90 days in this example, but could be 2-3 years based on your scenarios). Also, if we specify the conditions properly, the schedule-triggered flow might not be as overloading as we imagine. Unfortunately, I can’t find any accurate comparison on the two, so I would suggest “use schedule-triggered flow when it’s a separate set of actions and using scheduled actions when you can add it to some nodes in your existing processes or flows.”

Flow Chart (Account Contact Relationship)

Steps (Account Contact Relationship)

Please wait while flipbook is loading. For more related info, FAQs and issues please refer to DearFlip WordPress Flipbook Plugin Help documentation.

Result (Account Contact Relationship)

Schedule-Triggered FlowGet RecordsAction

Does the solution solve your problem? If not, write us what your problem is and we will build the flow for you!

Official Salesforce Help Article On Flow

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments