web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / RunDesktopFlow Bounded...
Power Automate
Unanswered

RunDesktopFlow Bounded Action with Application User

(0) ShareShare
ReportReport
Posted on by 60 Season of Giving Solutions 2025

Is there a way to share a Desktop Flow with an Application User in Power Automate?

 

I have written an Azure Function that uses the Dataverse API to trigger a desktop flow; however, when the code runs I get the following error: Operation returned an invalid status code 'Forbidden'. I am the owner of the flow and it has not been shared with any other users.

 

For authenticating with the Dataverse I have followed the steps in this post Use OAuth authentication with Microsoft Dataverse. I have created an App in Azure Active Directory, an Application User in Power Automate, and I am using the below code to authenticate.

 

Following these steps I am able to successfully connect to the Dataverse and query data in tables but I am unable to trigger a desktop flow.

 

Any feedback would be appreciated. I am open to changing my code and means of authenticating if it will enable me to trigger a desktop flow via Azure Function.

 

string SecretID = "00000000-0000-0000-0000-000000000000";
string AppID = "545ce4df-95a6-4115-ac2f-e8e5546e79af";
string InstanceUri = "https://yourorg.crm.dynamics.com";

string ConnectionStr = $@"AuthType=ClientSecret;
 SkipDiscovery=true;url={InstanceUri};
 Secret={SecretID};
 ClientId={AppID};
 RequireNewInstance=true";
using (ServiceClient svc = new ServiceClient(ConnectionStr))
{
 if (svc.IsReady)
 {
 //your code goes here
 }

}

 

 

I have the same question (0)
  • Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    I would suggest building a cloud flow that is triggered via an HTTP trigger (or a manual trigger) and launches your desktop flow.

    Then call the cloud flow from your Azure app.

    -------------------------------------------------------------------------

    If I have answered your question, please mark it as the preferred solution.

    If you like my response, please give it a Thumbs Up.

    If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/

     

     

  • slypdog93 Profile Picture
    60 Season of Giving Solutions 2025 on at

    I have considered that approach; however, I would like to avoid (1) Creating a cloud flow to wrap every desktop flow and (2) being limited by the Desktop Flows connector to running on a dedicated machine or using machine groups. I would like the flexibility to control which machine the desktop flow is being deployed to.

  • Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    In that case, I would assume you will need to build your own API endpoint that triggers a local PowerShell script (or similar) on a machine you provided that launches the desktop flow there.

    -------------------------------------------------------------------------

    If I have answered your question, please mark it as the preferred solution.

    If you like my response, please give it a Thumbs Up.

    If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 252 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 169

#3
Haque Profile Picture

Haque 154

Last 30 days Overall leaderboard