Why Keeping Your Flow API Versions Updated Matters

Why Keeping Your Flow API Versions Updated Matters

Salesforce Flow is one of the most powerful and popular tools in Salesforce. It keeps getting better with every release, introducing new features and enhancements that make it even more capable. While most updates work regardless of the Flow API version, some enhancements only become available after a certain API version is set. That means even if your Flow looks fine, it might be missing out on useful improvements behind the scenes. Keeping your Flow API version updated ensures you’re taking full advantage of the latest capabilities and performance optimizations.

Here are a few reasons why it’s important to keep your Flow API version updated.

How to change the API version of the Flow

No More Flow Element Iteration Limit

Previously, there was a Flow-specific limit that triggered when a flow executed 2,000 elements (ITERATION_LIMIT_EXCEEDED). This often caused issues in larger flows with loops. While there were some workarounds, it remained a common challenge. Salesforce removed this limitation in the Spring '23 release. However, your Flow’s API version must be set to 57 or higher to take advantage of this update.

Field Changes from Approvals Trigger Record-Triggered Flows

Before the Spring '22 release, field updates made by an Approval Process didn’t trigger flows. With Spring '22, record-triggered flows can run when fields are updated by approval processes, but only if the Flow API version is 54 or higher. To take advantage of this feature, you need to update the API version of your existing flows. Read this post to learn how to use Flow to save approval information to record fields.

Reactive Screen Components

Salesforce introduced reactive screen components in the Spring '23 release. With reactive screen components, your screen components can react to a user’s actions on the same screen.

Reactive screen components are readily available for Flows running on API version 59 and later without any additional configuration. For Flows running on API versions 57 and 58, you need to enable the reactive components feature by checking the "Enable Reactive Components for Specific Flow Versions" checkbox in Process Automation Settings. Therefore, it's recommended to upgrade your Flows to API version 59 or higher.

Reactive Screen Components Available in Flow API Version 59 or Higher

“Where is this used?” Doesn’t Catch Fields Used in Flow Entry Formula

Salesforce's "Where is this used?" functionality helps users find where a specific field is referenced within their Salesforce organization. This is particularly useful for understanding the impact of changes to a field, such as deleting or modifying it. The feature reveals where the field is used in various metadata types, including validation rules, Apex classes, Flows, and more.

If a field is used in a Flow entry criteria formula, "Where is this used?" can catch it only if the Flow API version is 61 or higher. This means that if the field is used in the entry criteria formula of a Flow with a lower API version, it might even let you delete the field!

Merge Field Evaluation Behavior by Flow API Version

If data coming into a Flow includes text that contains a merge field, the merge field displays the notation instead of the evaluated value. This behavior, introduced in API version 55 and higher, helps prevent unintentional data exposure and improves flow stability. In API version 54 and earlier, merge fields display the evaluated value.

For example, suppose the Account description includes text with merge fields.

Account Description

Let's display this field using a display text component.

Display Text Component

If the Flow API version is 55 or higher, Flow displays the text as-is and doesn’t evaluate the merge field values.

Display Merge Fields - Flow API Version 55

However, if the Flow API version is lower than 55, Flow evaluates the merge field values.

Display Merge Fields - Flow API Version 54

Summary

Most Flow updates work without changing the API version, but some features require a higher version to activate. Even if your Flow runs fine, it might miss key improvements. Updating the API version helps you benefit from the latest enhancements.

On the other hand, Salesforce occasionally retires older API versions. For example, Platform API versions 21 through 30 (SOAP, REST, and Bulk APIs) are scheduled for retirement soon. While this doesn’t affect Flow, it’s no guarantee that Salesforce won't retire Flow API versions in the future. All things considered, it’s a good practice to keep your Flow API versions updated as well.

Be the first to comment

Leave a Reply

Your email address will not be published.


*