Choose the Right Automation Tool
After completing this unit, you'll be able to:
- List the tools included in Salesforce Flow.
- Describe the tools available for automating guided visual experiences.
- Describe and compare the tools available for behind-the-scenes automation.
- Describe the tools available for approval automation.
People Expect Automation
No matter whether they’re buying movie tickets, paying bills, or changing restaurant reservations, if a customer is interacting with a company, they expect a seamless, personalized experience.
For example, when a customer needs to replace her credit card, the average service agent needs to know a bunch of things. Is it damaged, lost, or stolen? If it’s stolen, is she worried about recent transactions? Where should we send the new card? Serving a customer in this situation and gathering and maintaining related data can involve separate systems with varying degrees of complexity.
Automation Used to Be Hard
Providing a seamless, automated customer experience has historically been challenging, time-consuming, and code-heavy. Depending on the precise nature of your business processes, you may have had to:
- Integrate various systems.
- Configure process logic.
- Design and build an end-user experience.
- Make the experience available from anywhere: desktop or mobile devices, internal apps, or external portals.
Meet Salesforce Flow
Salesforce Flow provides declarative process automation for every Salesforce app, experience, and portal.
Included in Salesforce Flow are two point-and-click automation tools: Process Builder, which lets you build processes, and Flow Builder, which lets you build flows.
To sum up the differences:
- Salesforce Flow is the name of the product.
- Process Builder and Flow Builder are the names of the tools.
- Use Process Builder to make processes; use Flow Builder to make flows.
Later, we talk about when to use each tool, but for now here’s a sneak peek at what business processes look like in each tool.Process Builder Flow Builder
With these two tools, Salesforce Flow makes it easy for you to do the following.
|Use Case||Salesforce Flow Functionality|
|Create a guided tutorial or wizard with screens.||Flow Builder includes several out-of-the-box screen components, like text boxes, radio buttons, and file-uploads. If you need more than what’s offered, add custom Lightning components to your screens.|
|Set up automated tasks and processes.||Declaratively configure logic and actions for your business process with either Flow Builder or Process Builder. If needed, you can build custom Apex code to fill any functional gaps.|
|Connect to external systems.||Communicate changes between your Salesforce org and your external systems with platform events.
Flow Builder and Process Builder let you respond to and send platform event messages. In addition, Flow Builder can retrieve data from third-party systems with External Services.
|Add automation to your pages and apps.||Make sure your behind-the-scenes processes start when the right action happens, whether that’s when records change or when users click a particular button.
Once you build guided visual experiences, add them to Lightning pages, Experience Builder pages, the utility bar in your Lightning apps, and more.
|Reuse what you build.||In Flow Builder, any flow can be used as a subflow.
In Process Builder, create an invocable process to reuse that process’s logic or actions in other business processes.
Which Automation Tool Is Right for My Use Case?
When it’s all said and done, a process-driven experience isn’t backed by only one process. It’s a combination of all the business processes in your org that can impact your customer. Each business process typically falls into one of these camps.
|Type of Business Process||Description||Available Tools|
|Guided visual experience||Business processes that need input from users, whether they’re employees or customers.||Flow Builder|
|Behind-the-scenes automation||Business processes that get all the necessary data from your Salesforce org or a connected system. In other words, user input isn’t needed.||
|Approval automation||Business processes that determine how a record, like a time-off request, gets approved by the right stakeholders.||Approvals|
From Processes to Flows to Apex
One of the hardest things for an admin or a developer to figure out is when to use what tool for the job at hand. In general, it’s best to start with declarative, no-code tools and work your way up to code solutions.
Use Process Builder when you need to start a behind-the-scenes business process automatically. Processes can start when:
- A record is created
- A record is updated
- A platform event occurs
Use Flow Builder to:
- Automate a guided visual experience.
- Add more functionality for a behind-the-scenes process than is available in Process Builder. Use Flow Builder to build the more complex functionality. Then call the resulting flow from the process.
- Start a behind-the-scenes business process:
- When a user clicks something, like a button
- When a record is created
- When a record is updated
- When a platform event occurs
- At a specified time and frequency
For example, when an opportunity is won, your company wants a renewal opportunity to be created automatically. As you see later in this module, you can build parts of that use case as a process, but the rest has to be built in a flow.
Use Apex when you need more functionality than is available in Process Builder or Flow Builder. Build the more complex functionality as invocable Apex methods. Then call the resulting Apex as an Apex action in the process or as an Apex action element in the flow.
Now, let’s see these principles in practice with a few sample scenarios.
|Scenario||Tool||What You Build|
|Guide a site member through requesting a new credit card with a step-by-step wizard.||Flow Builder||Flow|
|A sales rep clicks a button on an opportunity, which launches a discount calculator.||Flow Builder||Flow|
|When an account is updated, update all of the contacts related to that account.||Flow Builder or Process Builder||Flow or Process|
|When an opportunity stage is updated, also update a custom checkbox field.||Flow Builder or Process Builder
||Flow or Process|
|Create a task when a platform event occurs.||Flow Builder or Process Builder||Flow or Process|
|Update a lead record in Salesforce after a certain amount of time passes, or when a specified time is reached.||Flow Builder or Process Builder
||Flow or Process
|When an opportunity closes, automatically create a renewal opportunity.||Flow Builder||Flow|
|Route an employee’s time-off request to a manager for approval.||Approvals||Approval process|
Wait. What’s an Approval Process?
Surprise! We snuck another tool in here. Approvals isn’t included in Salesforce Flow, but it offers a declarative way to automate something that Salesforce Flow doesn’t cover. That said, Salesforce Flow does support automating how a record gets submitted for approval. You’ll learn more about Approvals later in this module.
What About Workflow Rules?
If you’re not already using Workflow, you should check out Flow Builder and Process Builder first. They have more features and can do more things. Plus, Flow Builder includes all-new functionality for behind-the-scenes automation.
You can learn more about Workflow by visiting Salesforce Help.
- Salesforce Help: Which Automation Tool Do I Use?