Like me, I know, many of you also belong to the Fan club of Power Automate (or MS Flow as it used to be). It makes many of the complex data processing and computations a piece of cake. I so liked the combination of SharePoint, PowerApps and Power Automate that they became my defacto combo to start thinking about any solution with Teams to put everything together.
So, if the Power Platform with other Microsoft 365 Applications is so great, then why this article?
Background
Let’s set some background before we jump into the topic. Recently, I was working on a concept about how to measure Microsoft 365 User Adoption based on Collaboration Score. And if you look at the article, the concept is simple enough, but requires the Power Automate to iterate for all the users we want to calculate the scores for. And, that is where the list of limitations starts!
Documented Limitations
Well, it’s not that the MS is hiding something, there is an article documenting all these limits already, well most of it, so, why not just follow that and try to stay within those limits? The answer is simple – Those are NOT hard limits. The below quote from MS Support sums it up
Power Automate typically allows higher count than the documented number in the document, and will not slow flows down based on occasional and reasonable overages.
So, what’s that big limitation which this article title talks about? API Requests Limits! I talked to a couple of fellow Power Platform enthusiasts and found out this these limitations are not well understood. Like all those big numbers that microsoft tools normally provides, it’s just assumed that these limits are big enough to not to worry. Apparently that’s not the case.
Let’s jump in to more details.
API Request Limits
The article about Power Platform Requests and Limits talks about a bunch of thresholds and limits, but we will focus more on the Power Automate in this article.
What’s a Power Automate API Request
Before we can get started with how many requests your Power Automate is making, we need to establish what is counted as a request. So, plain and simple – All Power Automate step actions. So essentially, any action you add in your Power Automate – Set Variable, if conditions, Scopes everything and if you add a loop the just count those as many times as your loop runs.
Every card in a flow that gets executed counts as an API call (action). This includes both actions that result in outgoing calls (e.g. calling SharePoint) and actions that don’t (e.g. variable setting, delays, etc.). Only completed and failed actions (but not skipped) count toward the limit. This is explained in the document https://support.microsoft.com/en-us/help/4531688/troubleshooting-slow-running-flows
Simply put in MS support words, “If you have a loop that runs 5000 times and none of iteration in this loop is skipped, it will be counted at least 5000 API calls.”!
Why is this an Issue?
So, what if it counts each action as a request? Well, that’s because based on the License type, we only get a limited number of requests every day!
The daily API (or request) limit as of the date of writing this article is 2000 for users having Microsoft 365 E3 license and 5000 for users having per user plan on top of it.
Again in MS Support words “The daily API limit is counted for each account. It is not related to the number of users having per user license in the company, but related to the type of the license the user has. Each account can have multiple types of licenses. For example, your account have Office and Power Automate per user, the total API this account can make per day is 2000 + 5000 = 7000 (please note that this will be different for licenses within the same product line where the total API number of requests would be what is provided by the base license, not by the sum of the API numbers).”
To make it worse, these limits are not pooled, so regardless of the number of licenses your organizations have, this limit will be hit for the users under which the corresponding Power Automate runs.
Once the account in the flow hits the throttling limit, it can still try to make network calls but the flow performance might be affected. Every time it tries to make the call, it will be counted as one time hitting the limit.
Please note that this API daily limit is counted from all flows running by that account, not only from a single flow.
Other Limits
Well, daily API limit is just one part of the story.
- Connector throttling:. It relates to the throttling limit of each connector (the maximum number of actions that a single connection can execute per 60 seconds/ 300 seconds, etc depending on the connector). For example: each Sharepoint connection can make 600 API calls per minute: https://docs.microsoft.com/en-us/connectors/sharepointonline/#limits .
- Burst throttling. It relates to the max number of actions that the flow can execute in 5 min as specified here https://docs.microsoft.com/en-us/power-automate/limits-and-config#throughput-limits .
Under which account Power Automate Requests are counted
Now that we know there are quite some limitations, the natural question could be, I have on service/functional account which I use for all such Power Automate that we develop for users. Will all these API requests be counted under that account? Well, it depends.
- Automated Flow: The daily API consumption will always be calculated on the main owner/ the original flow creator. Adding the second owner will not affect the account against which the API calls are counted. If there is just one owner, you can create a flow with just HTTP action and share it to the users. If you want to change the original flow creator for the API consumption to be calculated on a new account, such as when the original flow creator moves out of your organization, the way to change the creator today is by exporting and importing the flow.
- Manual Flow: The daily API consumption will always be calculated on under the User Account that runs the flow (for flow that runs in the context of User Account such as Manual trigger for SharePoint list/library selected item).
But wait, what if the original Power Automate creator leaves the organization? Hmmm… in that case, the flow will not stop working as long as it has an active owner (either the original owner or co-author owners). Please look at the reference here. If he/she is the only owner of the flow (that is, the flow was not shared to any other accounts), and his account is deleted when he leaves the organization, then the flow will not work.
When the creator leaves, the flow will eventually be throttled down to free levels, which are entitled for 2000 API calls per day. It is recommended to switch the flow to a new creator either by exporting and reimporting the flow, or the other way is by turning off the current flow, save a copy with a new owner and re-enable the new flow.
Can we extend these limits?
As you can imagine, these limits seem to be too low where any processing of users/data is required which include loops. In no time, you will be beyond your allocated limits. Good news is that if you need to run your Power Automate less frequently, you should still be fine. I was able to successfully run Flows with more than 1.5 million actions! But this behaviour might change in future and you will be limited with your quota.
But what if you really want to extend – You can use Power Apps Capacity Add-On. As per the official MS article, Power Apps and Power Automate capacity add-on allows customers to purchase additional requests. Eventually, these may be assigned to any user who has a Power Apps/Power Automate license. Each capacity add-on provides an additional 10,000 requests/24 hours which can be assigned to any user. Multiple capacity add-ons can also be assigned to the same user.
As of writing of this article, Power Apps and Power Automate capacity add-ons cannot be assigned to users yet. Assignment will be possible later in calendar year 2020. When supported these may be assigned to application and administrative and non-interactive users.
How can I Monitor my API Calls
We can only monitor it at individual Flow level currently. Go to your Flow and click on Analytics on top. You will need at least “per user license” assigned to you to see the analytics.
It will show the Actions in a chart view. As you can see in this example, the number of actions are way beyond (around 320K), against the quota of 7K!
If you continue to run such a flow frequently, you may receive such a message – “Your flow’s performance may be slow because it’s been running more actions than expected since 9/24/2020 9:30:48 PM (1 month ago). Your flow will be turned off if it doesn’t use fewer actions.” for your Flow and it may be disabled by Microsoft.
So, keep them under the limit!
Conclusion
I still like the Power Platform and it’s still my go to solution for any related requirements, but I am now more aware of what can and cannot be done. Where it might start costing a bit more and where to already look for alternatives like Azure Functions for additional processing.
Hope this helps.
Thanks,
Anupam
10 comments
You mentioned “1.5 million action” what does that mean? Are you able to run those in a single day with same user id?
That means I have 100s of actions which loops through 1000s of times. And yes, it was taking about 6 hours to finish.
Is it 2000/24Hr/user or 20K/24hr/user? I believe it is documented as 20K for enterprise license holders
20K is the limit when a user has “Dynamics 365 Enterprise applications” license assigned.
For any user with a normal Microsoft E3 license, the limit is 2000/user. This article explains it.
Hello! Thanks for all this valuable info!
I’ve been trying to find out why I got that message… Your flow will be turned off… as well and information about pricing and this is the best explanation I found (including Microsoft) !
Thanks a lot!
Valuable information for me. Thanks
Hello,
For anyone facing daily action limits or speed issues, if you do not want to purchase the capacity add-on, you can do several things to make flows more efficient & use less action API calls.
Look into
-Trigger Conditions
-Query Filters
-Filter Array Actions
-Select Actions
-SharePoint Batch Actions (Create, Update, & Delete with up to 1000x less actions)
Batch Create: https://www.tachytelic.net/2021/06/power-automate-flow-batch-create-sharepoint-list-items/
Batch Update: https://powerusers.microsoft.com/t5/Power-Automate-Cookbook/Batch-Update-SharePoint-List-With-External-Data/td-p/1365410
Batch Delete: https://www.tachytelic.net/2021/06/power-automate-delete-sharepoint-items/
I, I am running a power automate premium with 40k/action limit. These running heavily now in the transition period – but on production will be low, below the limit. BUT when I open some of the flows with new copilot view I get message ‘flow has too many actions’. Not sure what to do with this. Is there any risk for the flow to be blocked in the future ? thank you (i don’t see the message if i open via power automate buy i am worry not to have the flow turned off automatically)