Triggers in Power Automate

In this article, we are going to learn about Triggers in Power Automate. We are also going to see types of triggers and how to use them.

Triggers are basically the starters. It's like a push a button to initiate or start the workflow. Several connectors can provide triggers that can notify your app when a specific event occurs. The triggers can be classified as Polling Triggers and Push Triggers as part of power automate.

  • Polling Triggers: It is basically an event that periodically makes a call to your service to look for new data. When new data is available causes a new run of your workflow instance with data as an input. Under polling triggers, we have Postman and other Custom Connectors.
  • Push Triggers: It listens for the data on an endpoint they want to wait for an event to occur. When an event has occurred a new run of your workflow instance will be started. Office 365 Outlook, Gmail comes these work on the push triggers. Whenever a mail has been flagged up, the trigger will listen to our data on the endpoint and then the particular actions will happen.

We have three types of Triggers in Microsoft Power Automate,

  • Manually firing trigger
  • Recurrence Scheduled trigger
  • Trigger react to an external event

Manually Firing Trigger in Power Automate

These triggers are manually fired by the user or a program. The ones that you have a button, something like your power automate app, or you have an external application that fires a floor when needed are basically manually firing triggers.

For example, if you have an emergency you can call to 911 through your cellphone. Here, you are basically manually triggering the action of calling.

Let's make an Expense report using a manually firing trigger flow.

  • We go to the Microsoft Power Automate page. Click on Create >> Instant cloud flow.
  • Give some name to your flow. Select Manually trigger a flow and click on Create.
  • Here, we have our manually trigger button created. We need to input some fields to make it more informative.
  • Click on Add an Input. Select user input type as Text. Give some name to text field input. You can name it as Expense.
  • Add one more field of user input type Number. You can name it as Amount. Click on the Next step.
  • We want to send an email, here we have different email options available. Click on Send an email notification (V3).
  • Add receiver's email, subject, and the body of the email. In the body, we are adding Expense, Amount, and Location. Click on Add dynamic content.
  • From dynamic content select Expense. Here, the dynamic contents are alterable when we are running the trigger.
  • Similarly, choose Amount and City (Location). Click on Save.
  • Now Save and Test the flow. Click on test flow Manually.
  • Enter your Expense and Amount. Click on Run flow.
  • Now, our flow is successfully running. The flow has sent an email to the receiver's mailbox regarding the expenses.

Recurrence Scheduled Trigger in Power Automate

We have a recurrence or scheduled triggers that are set of triggers the ones that are fired on schedule. You may schedule a need of trigger to fire a month from now, a week from now, every hour, every five minutes, once in a year as per your convince.

These are totally independent of any external event. You cannot manually run them. It only runs when the schedule based on the internal power automate clock decides to run. The schedule is of course set by us. For example, an alarm clock is triggered at your scheduled time.

Creating Scheduled Triggered Flow

Let's, create a scheduled trigger flow reminding the user to drink water.

  • Click on Create from the left side panel. Select Scheduled cloud flow.
  • Name your flow. Select the date and time, also add the frequency of the flow. Click on Create.
  • We have our Recurrence Trigger ready. Click on the New step.
  • We will schedule an email to send every minute. Click on Send an email notification (V3).
  • We will write an email to remind drinking water. Click Save.
  • Save and Test the Flow.
  • First, run your flow Manually and then run Automatically. Click Test.
  • You'll have an email reminder to drink water. Every minute it will send one email.

Triggers reacting to external events in Power Automate

Triggers are the ones that they monitor and react to an external event, something like when the file is created in SharePoint, when an email is received, when some list item changed, when an item in the Common Data Service entity has been deleted, anything like that.

These are the events that are basically monitored and these triggers react to a sort of flow when changes happen. For example, a bite alarm attached to a fishing rod gets triggered when fish or any external object is gets caught.

Creating a Trigger reacting to an external event

Let's create a flow that sends an email notification when a file is added to the OneDrive folder.

  • Firstly, we need an Onedrive folder to monitor. Goto OneDrive site. Sign In to your Microsoft account.
  • Create a New Folder name DemoFolder.
  • Now, let's get back to our Power Automate Environment. Click on Create and select Automated cloud flow.
  • Give a name to a flow. Select trigger When a file is created (OneDrive). Click on Create.
  • Select the DemoFolder from OneDrive. Click New step.
  • Click to Send an email notification (V3).
  • Write an email body where the file gets added to OneDrive. You can even dynamically add the name of the file which gets added. Click on Save and Test.
  • As we are adding files manually here on OneDrive, select Manually triggered. Click on Test.
  • Go to your OneDrive. Now, add a file in a DemoFolder.
  • An email of file added would be sent to the email id.

This is how we create different types of Triggers and Flows. If we want to stop the flow from running we can simply do that by going to My Flows. Click on three dots beside the flow. Select Turn off.

0 results
Comment / Suggestion Section
Point our Mistakes and Post Your Suggestions