Reputation: 341
I have a SharePoint list that I am building a flow for in Power Automate. When a certain field's value is changed, I need to set an associated date field to the datetime the value was changed. Purpose is to later use that date to notify users if the next required action is not taken within 24 hrs. When I run flow with a literal quoted date, it works fine. The error I'm getting is "Invalid JSON. The value '05-15-2023' is not a valid number"
Edit: SetToCC is a datetime field.
Any help would be appreciated!!
Upvotes: 0
Views: 1594
Reputation: 341
This answer comes from v-zhoqian-msft on:
https://powerusers.microsoft.com/t5/Using-Flows/Power-Automate-HTTP-Post-Error-when-updating-datetime-field/m-p/2156581#M39113
Upvotes: 0
Reputation: 1497
What type of field is the SetToCC? Assuming it is a datetime type of field, haave you tried putting quotes around the value of the SetToCC property as well?
Try something like as the body payload.
{
"SetToCC":"@{formatDateTime(utcNow(), 'MM-dd-yyyy HH:mm')}"
}
Upvotes: 0