Update single SharePoint column in Power Automate with HTTP request

“Is there a way I can update a single column in Power Automate without showing it on the view I use on the update item?

“I don’t know enough about these HTTP requests to know which pieces are part of the code and which pieces are information that needs to be specific to my site/library.”


There are multiple situations when it’s better to use an HTTP request to update a single SharePoint column than the Power Automate action ‘Update item’.

You don’t want to see all columns in the ‘update’ action as there’re too many. But at the same time, you don’t want to create a special view for each update. Maybe you even have a huge list with view threshold. Or you’re using variables for the site url and list, and the ‘update’ action doesn’t offer you any column.

In all these situations it’s easier to use HTTP request to do the update (unlike some permission setting situations). There are multiple articles or discussion on what the request should look like. But I think most of them overcomplicate it with headers, metadata, type… as on the image below borrowed from here. How can you do it more easily?

Simple HTTP update

As before, start from the ‘Send an HTTP request to SharePoint’ action. The first part will be the same, select a Site Address and Method. But that’s it, now we’ll continue differently.

  1. We’ll add a method to the web service in the Uri. If we end the Uri with ‘/items(<ID>)’, we need to add complicated headers and body to tell the service what to do. But we can tell the service to do an update directly in the Uri by adding ‘/validateUpdateListItem’ method.
  2. As already mentioned above, with the ‘validateUpdateListItem’ method we can keep the headers empty. The service already knows that we want to do an update.
  3. Also the body will be simplified as the method needs just a list of columns to update inside ‘formValues’.

You can take the code from below and use it in your flow, just replace the <placeholders> with your column / value. Use the column internal name, not the display name.

Uri: _api/web/lists/GetByTitle('<ListName>')/items(<ItemID>)/validateUpdateListItem

Body:
{
    "formValues":[
	{
	    "FieldName": "<FieldToUpdate>",
	    "FieldValue": "<ValueToUpdate>"
	}
    ]
}

And if you need to update multiple columns, just add all of them inside the ‘formValues’.

Body:
{
    "formValues":[
	{
	    "FieldName": "<FieldToUpdate>",
	    "FieldValue": "<ValueToUpdate>"
	},
	{
	    "FieldName": "<FieldToUpdate2>",
	    "FieldValue": "<ValueToUpdate2>"
	}
    ]
}

Update: if you want to update person or group column, you’ll need a specific format for the value. The same applies also to the multiple choice column.

Summary

I’d say that the main point of this post is to understand that if the ‘Update item’ doesn’t work for some reason or if it looks complicated, you can always use the HTTP request. And it’s not as complicated as it may seem. I personally am using them in all of my approval / review flows, especially when building approval history table. Every time I need to update one or two columns, HTTP request is my preferred option.

And if you need, you might even update the item without creating another item version.


Do you struggle with the various expressions, conditions, filters, or HTTP requests available in Power Automate?

I send one email per week with a summary of the new solutions, designed to help even non IT people to automate some of their repetitive tasks.

All subscribers have also access to resources like a SharePoint Filter Query cheat sheet or Date expressions cheat sheet.

Zero spam, unsubscribe anytime.

13 Comments

Add a Comment

Your email address will not be published. Required fields are marked *