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 / How to Get Environment...
Power Automate
Answered

How to Get Environment URL and APP ID Dynamically

(1) ShareShare
ReportReport
Posted on by 13
Hi Community,
I have a Power Automate flow in which I am currently struggling to get the dynamic record URL. I tried copying the URL from the model-driven app and hardcoding it in the flow (with dynamic record ID). It worked perfectly, but my concern is that it may cause issues during deployment to SIT bcz it should be dynamic.

So, Basically, I want to make the Dynamic environment URL and the Dynamic App ID. Any help would be greatly appreciated.
Categories:
I have the same question (0)
  • Verified answer
    harshdeol Profile Picture
    619 Super User 2026 Season 1 on at
    Hi,
    For this, I have a child flow where I am passing the required parameters, and which returns me the Record URL as output. I run this child flow from other flows wherever needed. I would suggest you do the same.

    If you want to implement only in one flow or want somthing simple, then get the Environment URL and from the App ID from the "ModelDriven App" table by filtering the App with unique name. See attached Image for more details.
     

    Here is the Dynamic URL: 
    https://@{uriHost(first(outputs('List_rows-Model-Driven_Apps')?['body/value'])?['@odata.id'])}/main.aspx?appid=@{first(outputs('List_rows-Model-Driven_Apps')?['body/value'])?['appmoduleid']}&pagetype=entityrecord&etn=@{triggerBody()['text_1']}&id=@{triggerBody()['text']}
     
     
     
    -------------------------------------------------------------------------------------------------------------------------
    If your question got an answer, please click "Accept as Solution "✅, If you liked my answer, please hit the ❤️(Like) button.
    Thank you,
    Harsh Deol
  • Ank Profile Picture
    13 on at
    The idea of Child Flow sounds interesting. Thank you so much. This is exactly what I was looking for.
    Thanks again.
  • harshdeol Profile Picture
    619 Super User 2026 Season 1 on at
    You're welcomeHappy to help :)
     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 103 Super User 2026 Season 1

#2
Haque Profile Picture

Haque 87

#3
trice602 Profile Picture

trice602 63 Super User 2026 Season 1

Last 30 days Overall leaderboard