Generate Dynamics 365 record link in a Flow using CDS connector | Power Automate

There are several ways to formulate a Dynamics 365 record URL and make it clickable in a Flow in Power Automate.

Here’s one of the ways I follow for most scenarios – Let’s say I want to open a PSA Time Entry record from my Flow, here’s how I do it

Get record action to retrieve URL

Since this post is focused on CDS connector, I can get the D365 record link in body of Get record action for Common Data Service connector.

Unfortunately, I didn’t see this if the trigger was a CDS action, so I made a separate Get record call.

But, we’ll retrieve the same without having to select/parse body object. So let’s see –

Generating Link

First, I’ve initialized a variable that’ll hold the String format of the end URL
Now, first – I’ve appended https://. This won’t come directly using the uriHost() method

Then, the uriHost() holds the formula ‘uriHost(body(‘Get_record’)?[‘’])

Meaning, get the uriHost name i.e. Environment name itself.

Then, I’ve appended options for the window to open which are mentioned below in this post.

Finally, I’ve appended the Primary Key of the record itself at the end


Now, let’s talk about the options –

  1. cmdBar = [true | false]
    It’ll show the ribbon on the record. If false is chosen, it’ll be hidden
  2. navBar = [off | on]
    It’ll show the Navigation Bar on top if on. If off, it’ll be hidden
  3. newWindow=[true | false]
    This didn’t affect in my case. It anyway opened in a new tab. This could be different is the link is not opened from Email but is used elsewhere
  4. pagetype=entityrecord
    Since we are targeting a Dynamics 365 entity record, the above is used.
  5. etn= [name of the entity]
    Name of the entity
  6. id
    GUID of the record itself.

Here’s an Email that I composed to show how the URL will end up looking –

Which will result in Email like this


And open the record like this.
As per my settings in the URL I created, I don’t have the Nav Bar or Command Bar visible. It’s up to you to decide your preference

Here are some more Power Automate / Flow content you might want to check –

  1. Text Functions in a Flow | Power Automate
  2. Loop through array of objects in a Flow & Create records in CDS | Power Automate
  3. Get Count of records retrieved in CDS connector in a Flow | Power Automate
  4. Number Formatting in a Flow | Power Automate
  5. Call a Dynamics 365 Action from Flow [Bound and Unbound Actions] | Power Automate
  6. Make HTTP request from Flow in Power Automate
  7. Switch-Case in a Flow | Power Automate
  8. Setting Retry Policy for an HTTP request in a Flow | Power Automate

Hope this helps!!


5 thoughts on “Generate Dynamics 365 record link in a Flow using CDS connector | Power Automate

  1. Hi, is there a way to include the link in the email body so that when user clicks on it, it opens the crm record within the CRM mobile app (not in the mobile browser)?


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.