top of page

Subscribe to our newsletter

Automating Lead Follow-Ups with Do Until in Power Automate

  • Writer: Sivakumar K
    Sivakumar K
  • Dec 21, 2025
  • 4 min read

Learn how to use the Do until action in Microsoft Power Automate to automatically follow up on new leads until they are contacted. This article explains a real-world sales use case and shows how Do until helps ensure no lead is ever missed.


In sales and customer engagement, speed matters. When a new lead is submitted, delays in follow-up can directly impact conversion rates. But what if your team forgets to respond—or gets busy?

This is where the Do until action in Power Automate becomes extremely powerful.

In this article, we’ll see how to use Do until to continuously monitor a lead and automatically trigger follow-ups until the customer is contacted.



In this scenario, I’ll use SharePoint as the database and a Microsoft Teams channel to communicate with the team. The flow will automatically send a follow-up reminder every 2 hours until the lead is contacted.


Step 1: Create a SharePoint List

Create a SharePoint List with the following columns to store lead details, you can add more fields as per your need .

  • Full Name – Single line of text

  • Organization Name – Single line of text

  • Email Address – Single line of text

  • Mobile Number – Single line of text

  • Requirement – Multiple lines of text

  • Contacted – Choice column (Yes / No)

This list will act as the primary data source to track new leads and monitor whether the customer has been contacted.



Step 2: Create an Automated Flow

Create an Automated cloud flow and select the When an item is created trigger from the SharePoint connector.

  • Select the Site Address where the SharePoint list is created

  • Select the List Name containing the lead details

This trigger ensures the flow starts automatically whenever a new lead is added to the SharePoint list.


Step 3: Initialize Variable and Add Do Until

From Built-in → Variables, add an Initialize variable action and configure it as follows:

  • Name: varContacted

  • Type: String

  • Value: Leave it blank

Next, from Built-in → Control, select the Do until action.This will be used to repeatedly check the lead’s contact status and continue the follow-up process until the condition is met.

The Initialize variable action will be used to store the current status of the Contacted field, allowing the flow to track whether the lead has been contacted and control the execution of the Do until loop accordingly.



Step 4: Get Item and Update Contact Status

Inside the Do until loop, add the SharePoint – Get item action and configure it as follows:

  • Site Address: Select your SharePoint site

  • List Name: Select the lead tracking list

  • Id: Use ID from the When an item is created trigger

Next, add a Set variable action and update:

  • Variable Name: varContacted

  • Value: Select the Contacted field from the Get item action

Since this logic runs inside the Do until loop, the flow will continuously retrieve the latest record and update varContacted, allowing the loop to keep checking the contact status until the lead is contacted.



Step 5: Configure the Do Until Condition

Now, configure the Do until loop condition as follows:

  • Select the varContacted variable

  • Set the condition to is equal to

  • Enter the value Yes

  • Set the Timeout to PT12H

This ensures the loop continues checking the contact status until it becomes Yes, but stops automatically after 12 hours to avoid an infinite loop..



Step 6: Update Variable Using a Condition

Next, we need to update the varContacted variable when the Contacted field is changed to Yes in SharePoint.

Inside the Do until loop, add a Condition action from Built-in → Control and configure it as follows:

  • Condition:

    • Field: Contacted (from Get item)

    • Operator: is equal to

    • Value: Yes

If the condition is TRUE:

  • Add a Set variable action

  • Select varContacted

  • Set the value to Yes

Once this variable is updated to Yes, the Do until condition is satisfied and the loop ends automatically.

If the condition is FALSE:

  • The flow does nothing in the false branch

  • The loop waits and runs again, rechecking the Contacted field until it changes to Yes or the timeout is reached

This approach ensures the flow continuously monitors the lead status and exits the loop immediately once the customer is contacted.



We have now successfully implemented the core logic.The next step is to notify the team if the lead has not been contacted.

For communication, you can use any channel such as email, Microsoft Teams, or other messaging options. In this scenario, we’ll use a Microsoft Teams channel message.

Add the Microsoft Teams – Post a message in a channel action inside the FALSE condition box, because:

  • FALSE condition = Contacted is still “No”

  • This means the lead has not yet been contacted and follow-up is required

Each time the loop runs and the condition remains false, the flow will send a reminder message to the Teams channel, ensuring the team is alerted until the lead is contacted or the loop timeout is reached.



Final Step: Add Delay to Control Follow-Up Frequency

This is the most important step in the flow.

Since the follow-up must happen every 2 hours, we need to add a delay. If this step is missed, the flow will keep running continuously and spam the Teams channel, which can be annoying for the team.

Go to Built-in → Schedule and select the Delay action.

  • Count: 2

  • Unit: Hours

This ensures the flow waits 2 hours before checking again and sending the next follow-up notification.

👉 For testing purposes, you can change the delay to 1 or 2 minutes to quickly validate the behavior.

With this delay in place, the flow sends controlled, periodic reminders until the lead is contacted or the Do until timeout is reached.



Comments


bottom of page