Create the Recommendation Strategy Flow for Next Best Action

To determine how and when to present the Einstein Next Best Action recommendation on a Lightning page, create a Recommendation Strategy flow with Flow Builder. In the flow, use the keywords or signals to show the right recommendations.

Required Editions

View supported editions.

Flow Builder offers more flexibility and power than Strategy Builder. Flow Builder can also better integrate with customer data in Salesforce. To understand the Flow Builder limitations, review the flow limits.

When you create a Recommendation Strategy flow, it comes preconfigured with a recordId and outputRecommendations variables. To pass input to the flow, add variables to the flow. For details, see Input Variables for the Recommendation Strategy Flow.

  1. From Setup, in the Quick Find box, enter Flows, and then select Flows.
  2. To create a Recommendation Strategy flow, click New Flow, select Start from Scratch, and then click Next.
  3. Select Recommendation Strategy and click Create.
  4. To add the other required variables, intelligenceSignals and ruleDevName, open the Toolbox. For each additional variable, click New Resource, and select Variable as the resource type.
    New Resource page
  5. To check which Conversation Intelligence rule was triggered and route the call to the appropriate NBA, add a Decision element to the flow. For each NBA that you want to display, add an outcome branch with these settings.
    1. In the Label field, enter a name that identifies the NBA.
    2. In the Condition Requirements field, select All Conditions Are Met (AND).
    3. In the Resource field, select ruleDevName.
    4. In the Operator field, select Equals.
    5. In the Value field, enter the developer name of your Conversation Intelligence rule.
    If the flow suggests an auto-complete value matching your Decision path name, do not select it. It points to the Decision Outcome, not the developer name of the rule.
  6. To get the Recommendation records, add a Get Records element below each decision branch. To filter what recommendations are retrieved, add conditions.

    For example, add a condition based on intelligenceSignals fields, such as intelligenceSignals.category or intelligenceSignals.matchedKeywords.

    Tip
    Tip To find the Recommendation record name, go to App Launcher, search for Recommendations, and copy the name from the record.
    New Get Records page
  7. To assign the retrieved recommendation records to the outputRecommendations record variable, add an Assignment element to the flow.
    Edit Assignment page
  8. Save and activate the flow.
    Edit Assignment page