Forum Discussion

Ximo's avatar
Ximo
Brass Contributor
Feb 09, 2023

Publish summary information for the project with REST in Power Automate

Hi,

I am trying to update the calculated custom fields for ongoing Projects and would like to know if there is a REST operation (or any other way) that could do the same as the SharePoint Designer 2013 action "Publish Project Summary":

 

 

The requirement is to update the calculated Custom Fields without Publishing the Project Plan as we have some KPIs related to when was the last time the Project Manager published the Project Plan.

 

There is a calculated Custom Field that sets the Project to Late or Overdue based on the current date, so if the Project Manager did not update the Project Plan or saved Project data in a PDP the calculated Custom Field is not refreshed and the value is not accurate.

 

The goal is to daily run a Power Automate action that refreshes this calculated Custom Field on Projects that were not udpated so the value remains accurate.

 

UPDATE:

 

I am trying to update a Custom Field with ProcessQuery to check if the other Custom Fields get refreshed when using the Update method: 

 

 

But getting the following error about the Constructor TypeId

 

 

"ErrorMessage": "The 'TypeId' attribute is invalid - The value '{3a609e855f-e2a1-497c-87a2-e5e8a781d096}' is invalid according to its datatype 'http://schemas.microsoft.com/sharepoint/clientquery/2009:TypeIdGuidType' - The Pattern constraint failed.",

 

 

 

This the XML body:

 

 

<Request xmlns="http://schemas.microsoft.com/sharepoint/clientquery/2009" SchemaVersion="15.0.0.0" LibraryVersion="16.0.0.0" ApplicationName="Javascript Library">
    <Actions>
        <Method Name="SetCustomFieldValue" Id="14" ObjectPathId="8">
            <Parameters>
                <Parameter Type="String">Custom_6ef30e58-88a9-ed11-98fd-00155d9c3d86</Parameter>
                <Parameter Type="String">Updated via Power Automate on @{utcNow()}</Parameter>
            </Parameters>
        </Method>
        <Method Name="Update" Id="15" ObjectPathId="6" />
    </Actions>
    <ObjectPaths>
        <Property Id="4" Name="Projects" ParentId="0" />
        <Method Id="8" ParentId="6" Name="GetById">
            <Parameters>
                <Parameter Type="String">@{items('Apply_to_each')?['Id']}</Parameter>
            </Parameters>
        </Method>
        <Constructor Id="0" TypeId="{3a609e855f-e2a1-497c-87a2-e5e8a781d096}" />
    </ObjectPaths>
</Request>

 

 

 

Where can I find the appropriate Constructure TypeId value? In the suggested URL, the service is unavailable:

https://schemas.microsoft.com/sharepoint/clientquery/2009:TypeIdGuidType 

 

 

Thank you in advance!

 

 

No RepliesBe the first to reply

Resources