Skip to main content
These recipes show how to automate common retail execution follow-ups with Salesforce Flow on FieldKo objects. Each recipe lists the object, trigger, entry conditions, and steps, using the labels you see in Flow Builder. Adapt the thresholds and recipients to your business. Before you build any of them, read Design Automation for FieldKo. Rep records arrive in batches when reps sync, so every recipe here uses entry conditions, avoids elements inside loops, and sends notifications on an asynchronous path so that a failure can’t block a rep’s sync.
Flowchart of a rep's sync: offline work uploads in size-based batches with parents before children, each batch runs through Salesforce's order of execution including your flows and FieldKo's automation, and an unhandled flow error rolls back that record, causing a partial sync that repeats until fixed.Flowchart of a rep's sync: offline work uploads in size-based batches with parents before children, each batch runs through Salesforce's order of execution including your flows and FieldKo's automation, and an unhandled flow error rolls back that record, causing a partial sync that repeats until fixed.

How Rep Records Arrive and Run Your Automation

User Permissions Needed

Before You Begin

  • Decide how to reach managers. Several recipes notify the rep’s manager through the Manager field on the rep’s user record. If you don’t use that field, for example because your managers come from roles or public groups, send the notification to a public group or queue instead.
  • Create a custom notification type if you send custom notifications. See Notifications and Email Alerts.
  • Add your bypass check. Start each flow with the integration-user bypass described in Bypass Your Flows for Integration Users.

Recipes at a Glance

Alert a Manager When a Compliance Check Fails

Tell a manager right away when a rep records a failed compliance question, such as “Is the promotional display in place?” answered “No”. This supports promotion compliance and planogram compliance follow-up. FieldKo doesn’t mark which questions are compliance checks, so first add a checkbox, such as Compliance Question, to the Question object, and select it on the questions you want to watch.
  • Object: Task Survey Answer
  • Trigger: A record is created or updated. Optimize for Actions and Related Records.
  • Entry conditions: Question Definition is not blank.
Build the flow with these steps:
  1. Add a Decision element that checks whether Question Definition > Compliance Question equals true and Answer equals No. Because Answer is a long text field, check it in a Decision element instead of in the entry conditions.
  2. Optional: Add an outcome for scored surveys, where Score Obtained is less than your threshold. The FieldKo packages and the FieldKo Atlas app (version 1.0.70) don’t calculate scores. They don’t fill in Score Obtained or Out of Score. Scores appear only if your organization has its own automation that calculates them. Before you rely on this outcome, check that recent survey answers in your org have Score Obtained filled in.
  3. On the failed outcome, add an asynchronous path, and then add a Send Custom Notification action. Set the recipient to Task Survey > Visit > Sales Representative > Manager, and set the target to the visit.
  4. In the notification body, include the account name (Task Survey > Visit > Account > Account Name), the question, and the answer.
Use the lookup path through Task Survey and Visit to find the rep. The Sales Representative field on the survey answer itself is a text field, not a user lookup.

Follow Up on an Out-of-Stock Product

When a rep records core ranging and a contracted product isn’t on the shelf, create a follow-up so someone acts on the out-of-stock. Each time a rep saves ranging, FieldKo creates a new Ranging record with one Ranging Line Item per product, and the line items upload after the ranging record. Trigger on the line items, not the ranging record. A store visit can produce many missing products at once. To keep follow-ups manageable, add a checkbox such as Must Stock to FieldKo Product, and act only on those products.
  • Object: Ranging Line Item
  • Trigger: A record is created. Optimize for Actions and Related Records.
  • Entry conditions: Is Present equals false. If you use your own ranging columns, use your own out-of-stock field instead.
Build the flow with these steps:
  1. Add a Decision element that continues only when Product Name > Must Stock equals true. (Product Name is the line item’s lookup to the FieldKo product.)
  2. Add a Create Records element for a Salesforce Task (the standard activity, not a FieldKo task). Set Related To to Ranging > Account, Assigned To to the account owner, a due date, and a subject that includes Product Name > Product Name.
  3. Add a fault path that emails your admin team, so a failed task doesn’t block the rep’s ranging.
To put the follow-up on the next visit instead, create a Next Visit ToDo’s record with Next Visit Entry child records for the task types to do. FieldKo keeps only one active to-do per account and assignee: saving a new active to-do deactivates the existing one, including one a manager created. Check for an active to-do first, and add your entries to it. The NextVisitToDoAssigneeSchedular job applies to-dos created in Salesforce to the next planned visit. See Scheduled Jobs.

Notify the Account Owner About a Large Order

Let the account owner or key account manager know when a rep places an unusually large order.
  • Object: FieldKo Order
  • Trigger: A record is created. Optimize for Actions and Related Records.
  • Entry conditions: Order Amount is greater than or equal to your threshold.
Build the flow with these steps:
  1. Add an asynchronous path.
  2. Optional: Add a Decision element that skips return orders by checking the order’s record type.
  3. Add a Send Custom Notification action, or an email alert, to Account > Owner ID (ID stands for identifier). Set the target to the order.
The app sets Order Amount when the rep places the order, so it’s available when the order is created, even if some order lines upload in a later batch. To act only on orders that need sign-off, see Approvals for Leave, Orders, and Campaigns.

Flag Stores Not Visited in X Days

Find stores that have fallen out of coverage. FieldKo keeps these fields current on each account:
  • Last Check-Out: The date of the last completed visit
  • Next Visit Plan Date: The date of the next planned visit
  • Days since Last Checkout: A formula based on Last Check-Out, useful in reports and list views
Build a schedule-triggered flow that marks uncovered stores:
  1. Add a checkbox, such as Coverage Gap, to Account.
  2. Create a schedule-triggered flow that runs daily on Account. Filter it to your store record types, the ones selected in Account Record Types for Visit Planning.
  3. Add a Decision element with a formula outcome that’s true when Last Check-Out is blank or more than X days ago, and Next Visit Plan Date is blank or in the past.
  4. On that outcome, set Coverage Gap to true. On the other outcome, set it to false if it’s currently true.
Then build a list view or report on Coverage Gap for managers. See Plan Visits in Salesforce.
Updating accounts adds work to every account in the run, and FieldKo’s own account automation runs on each update. Update Coverage Gap only when its value changes.

Notify a Manager When a Visit Is Canceled

Tell a manager when a rep cancels a visit, with the reason, so call compliance problems surface the same day.
  • Object: Visit
  • Trigger: A record is updated. Optimize for Actions and Related Records.
  • Entry conditions: Status equals Cancelled. Select Only when a record is updated to meet the condition requirements.
Build the flow with these steps:
  1. Add an asynchronous path.
  2. Add a Send Custom Notification action to Sales Representative > Manager, with the visit as the target.
  3. In the body, include the account and the reason. Visits canceled in the app store the reason in Check Out Compliance Reason. Visits canceled in Salesforce store it in Reason For Incompletion and Incompletion Remark.
In Salesforce, canceling a visit that’s already in progress completes it instead of canceling it. To catch those visits too, add an outcome for Status changed to Completed with Reason For Incompletion filled in.

Test Your Flows

Test each recipe in a sandbox before you activate it in production:
  1. Log in to the FieldKo Atlas app as a test rep in the sandbox. See Manage Releases: Sandboxes, Deployments, and Package Upgrades.
  2. Complete several visits offline, with surveys, ranging, and orders that meet and don’t meet your conditions.
  3. Sync once, and then check that the right notifications arrived and that the rep’s sync finished without issues in Sync Details.

Best Practice

Close the Loop on Store Exceptions

A store problem found on a visit should end in a fix someone has checked, not in a report nobody reads. FieldKo has no standard object that holds an exception’s owner, due date, and verified closure, so you build the loop from incidents, Next Visit To Do’s, and the flows on this page. Use it for findings that need someone other than the rep to act, or a second visit to confirm: out-of-stocks on must-stock products, missing displays, price errors, damaged stock, and safety issues.
Three options for the exception loop: Next Visit To Do's (built in, but no owner, due date, or verification), an incident routed by a flow (owner and due date on the flow's task), or a case or custom object you configure with owner, due date, and status.Three options for the exception loop: Next Visit To Do's (built in, but no owner, due date, or verification), an incident routed by a flow (owner and due date on the flow's task), or a case or custom object you configure with owner, due date, and status.

Three Ways to Build the Exception Loop in FieldKo

Option B: route an incident with a flow. The rep logs an incident with a Subject, a Priority (High, Medium, or Low), a description, and an optional photo; it records the account and the visit. See Log an Incident. Build a record-triggered flow on the incident that creates a Salesforce Task (the standard activity) with an assignee and a due date, or sends a notification, following the patterns above. Track closure on that task, since the incident has no owner, due date, or resolution status of its own. Treat Critical as High plus your escalation procedure, unless you add your own severity field. Option C: use a Case or a custom object. If you need one record with owner, due date, status, and verification, configure Salesforce Case or a custom object with the fields below, a status picklist with the closure stages, and lookups to the account, visit, and product. A flow can create it from an incident, a survey answer, or a ranging line item that isn’t present. First read Extend FieldKo Safely. FieldKo doesn’t include a standard pattern for this; if you’re unsure which option fits, ask your FieldKo contact. What to record for each exception: store, product or campaign, observed condition, the standard it breaks, evidence, severity, likely cause (unconfirmed until checked), owner, next action and due date, status, and verification evidence. Set severity. Example levels, not an industry standard: Critical (safety, product integrity, major contract risk: immediate escalation), High (a must-stock product or promotion failing in a time-limited window), Medium (fix by the next scheduled visit), and Low (review monthly).
A store exception moves from Detected to Triaged, Actioned, Verified, and Learned; it's closed only when new evidence shows the fix. Side paths cover authorized exceptions, issues not reproducible, and issues reopened.A store exception moves from Detected to Triaged, Actioned, Verified, and Learned; it's closed only when new evidence shows the fix. Side paths cover authorized exceptions, issues not reproducible, and issues reopened.

The exception closure loop.

Keep closure stages separate: Detected, Triaged, Actioned, Verified, and Learned, with side paths for Authorized exception, Not reproducible, and Reopened. A completed task or a scheduled to-do is not a fix; count an exception as closed only when new evidence shows the change. Run a 30-minute weekly review: overdue critical issues first, then high-severity campaign and availability exceptions, then repeating patterns. Leave with a decision log of owner, due date, and how each item will be verified. Fictional example. A regional manager’s reps record 20 exceptions in a week; 15 are due. 12 have a later survey answer showing the fix, so the verified closure rate is 12 / 15 = 80%. The 2 open high items are the same display at the same store, so the manager links them and escalates the blocker. These metrics need the owner, due date, and status fields from Option B or C. Report speed next to shelf outcomes, because speed alone rewards closing too early. Checklist: agree exception fields, severity levels, and cause categories; choose Option A, B, C, or a combination and document where each field lives; assign owners per cause; define verification evidence; build and sandbox-test the flow and reports; schedule the weekly review.

See Also

Last modified on October 27, 2026