Open Paused Flow Interviews in Flow Builder

Open Paused Flow Interviews in Flow Builder

When flows pause or fail, it is possible to view and monitor them from "Paused and Failed Flow Interviews" in Salesforce setup. You can see the failed flow interviews from "Failed Flow Interviews" list view. Moreover, you can click the interview label in order to open the flow interview in Flow Builder. This is a great way to see why the flow has failed. On the other hand, "Paused Flow Interviews" list shows the flow interviews that has paused. All the paused screen flows (using the pause button) and paused autolaunched flows (using the pause element) appear here. However, unlike failed flow interviews, it is not possible to click the interview label and open the flow interview in Flow Builder. Therefore, it is not possible to get more details and understand which record is waiting in the queue. However, you can do a little trick to open paused flow interviews in Flow Builder.

Paused Flow Interviews

How Salesforce Opens Failed Flow Interviews in Flow Builder

First of all, let's understand how Salesforce opens failed flow interviews in Flow Builder.

Failed Flow Interviews

After you click the interview label, Salesforce opens the flow interview in Flow Builder. This makes it easier to understand why the flow has failed. For instance, this flow interview has failed because of a custom validation rule.

Flow Interview in Flow Builder

Pay attention to the format of the URL.

https://sftime2-dev-ed.lightning.force.com/builder_platform_interaction/flowBuilder.app?flowId=301B0000000kN9W&guid=3299419c91f7912c745754d956921895e2c8683-6532

As you can see, there are 2 parameters in the URL: flowId and guid.

Let's create a screen flow that builds this URL using the flowId and guid of paused flow interviews.

Build a Screen Flow to Open Paused Flow Interviews in Flow Builder

1- Create a screen flow and add a Get Records element to get all the paused flow interviews.

Get Paused Flow Interviews

2- Add a Screen Element, rename the next button as "Open in Flow Builder" and add a Data Table.

Data Table to Display Paused Flow Interviews

3- Add Name, Interview Label, Pause Reason, Current Element, and Last Modified Date fields as columns. Optionally, rename the columns. For instance, you can rename the Interview Label as Flow Name.

Paused Flow Interviews Data Table

4- Create a formula (or text template) in order to build the URL.

Formula for the URL
LEFT({!$Api.Enterprise_Server_URL_570}, FIND('/services', {!$Api.Enterprise_Server_URL_570}))&
'builder_platform_interaction/flowBuilder.app?flowId='& {!PausedFlowInterviews.firstSelectedRow.FlowVersionViewId}&
'&guid='&{!PausedFlowInterviews.firstSelectedRow.Guid}

As you can see from the formula, you have to pass the FlowVersionViewId and Guid of the selected record.

5- There is no out of the box way to navigate to a URL. However, you can install Navigate Everywhere action from UnofficialSF and configure it to navigate to the URL that you built.

Navigate Everywhere Action

At the end, you flow should look like this.

End of the Flow

Demo

Here is how the screen flow works. As you can see, it opens the paused flow interview in Flow Builder.

Demo - Open Paused Flow Interviews in Flow Builder

Be the first to comment

Leave a Reply

Your email address will not be published.


*