Power Automate flows with Dataverse triggers stopped executing in environment. Let’s dive to the root cause.

Hello everyone and welcome to my blog. In today’s blog my intention is to go deep and explore the reason why certain power automate flows configured with DataVerse triggers stop executing.

Through my blog I share interesting tips and discuss on latest releases of Microsoft.NET technologies, Dynamics 365 and Power Platform, SharePoint and Client scripting libraries. Please subscribe to my blog to stay updated.

This behavior is usually observed when you perform the below operations

  • You perform a minimal copy of an environment and restore it.
  • You modify your trigger – For example trigger was initially for “When a record is created”. You change it to “When a record is deleted”.

To understand the issue, we first need to understand what exactly happen when an automated cloud flow is created with a DataVerse trigger. Let’s take the example of the below flow that trigger when a contact record is added in DataVerse

Quite unknown to many, there is a table in DataVerse to store the Power Automate flow triggers. The table name is ‘Callback Registration‘.

You won’t be able to locate the table from Power Apps maker portal or even through advanced find. But you can query the table from a flow.

To do this, I have created an on-demand flow to list the Callback Registration records.

When I execute the flow, I could find the trigger for the previous flow recorded in this table. Below is the JSON output for the trigger. I have collated only the important properties.

  1. name – The GUID of the flow
  2. message – SDK message for the trigger. In my example it is create. Hence value is 1.
  3. scope – scope of the flow

For CRUD operations, the message field provide the value. If your trigger is when an action step is performed, there is another column sdkmessage which will contain the name of the message.

Great. So now we know that all DataVerse triggers are stored in Callback registration table. Now let’s understand, why in certain scenarios, Power automate flows does not execute.

The first scenario is when we do a minimal copy of our environment and restore. The problem with minimal copy is only the customizations are copied and not the data. And this exclude Callback registration table data as well. I hope this is quite clear.

So when you perform a minimal copy, remember that power automate flows with dataverse trigger won’t execute once you restore the back up.

The next scenario is when we change the trigger. In my example, I changed the trigger from Added to Added or Modified.

Now when I query callback registration table it has two records. One with message = 1 (create) and another with message = 4 ( Added or modified).

Now this was a surprise to me. I thought the old record would be deleted and a new one would be created. However as I found out, there is a field softdeletestatus which identify whether a trigger has been removed or is active.

In our case, the initial record now is marked with softdeletestatus = 1 and the new one has softdeletestatus = 0.

Sometimes when we change the trigger, due to some sync issues, if the new trigger record is not created in the Callback registration table, the flow will stop executing.

Ok. So by now you understand where things can go wrong. But how about solving the problem. Do I need to manually create an entry in the table for the trigger?

Well, we do not need to. In all cases I came across, deleting the the trigger and adding it again seem to do the magic trick. As I understand when we delete the trigger and re-create it, it creates the new record in the table and everything starts working as expected.

I hope this helped. If you have liked the post and if this post has helped you, please subscribe to my blog.

Debajit Dutta

1 thought on “Power Automate flows with Dataverse triggers stopped executing in environment. Let’s dive to the root cause.”

  1. Great Post.

    even i tried the below way to achieve this

    • disable the impacted flow
    • delete callbackregistation
    o fetch(‘https://.crm4.dynamics.com/api/data/v9.2/callbackregistrations(callbackId)’,{ method: ‘DELETE’})
    • enable the flow

Comments are closed.