Introduction
In this article, I will show you how to update hyperlink fields with URL and description in Share Point using Microsoft Flow (Power Automate).
Sometimes we have the requirement to add a URL in the Share Point list column and we can’t directly update the URL with a description using the Update Item action in MS Flow. So in this article, I will show you how to Update the URL with a description of the Share Point List.
Share Point List
I have already created a list with two fields, Title (single line of text) and Address (Hyperlink).
Steps to create Flow
Step 1
Open Power Automate
Link.
Step 2
Select the “Create” option from the Left Navigation Panel and then select “Automated cloud flow”
Step 3
Once you select the above option a dialog box will open. Enter details and Click on the “Create” Button.
Flow Name - Enter the name of your flow
Choose your flow’s trigger based on your requirement. Choose trigger from the list.
Step 4
Once you click on create your flow page opens with your action.
Enter your Site Address and List Name
Step 5
Click on Add New Action and add “Send an HTTP request to SharePoint “
Step 6
Fill in all the data details
Site Address - your Site Address
Method - POST
Uri - _api/web/lists/GetByTitle(‘ListName’)/items([ID]). Update “ListName” to your list’s name.
Replace “[ID]” with the ID field from dynamic content.
Step 7
Click on “Text Mode” in send HTTP request action.
Step 8
Add the below code in the Header Text Box
- {
- "Content-Type": "application/json;odata=verbose",
- "X-HTTP-Method": "MERGE",
- "IF-MATCH": "*"
- }
Step 9
Add the below code in in the Body Text Box
- {'__metadata': {'type':'SP.Data.RecordsListItem'},
- 'Address':{'Description': 'Click Here','Url': 'http://www.msn.com'}
- }
Step 10
Replace 'SP.Data.RecordsListItem’ with your own list’s name.
For getting ListItemEntityTypeFullName for your list use the below rest API
“_api/web/lists/GetByTitle(‘<List name>’)?$select=ListItemEntityTypeFullName”.
Step 11
Replace 'Address' with the name of the hyperlink column’s name
Step 12
Replace Description text with the label/description/clickable text you want for the link
Step 13
Replace http://www.msn.com with the URL/address part of the hyperlink