I am having some difficulty with Date/Time formats in my flow.
The Flow is triggered by PowerApps (Canvas App) and is creating events in a SharePoint calendar (classic calendar, not modern).
There are 2 parts to this flow. The first part creates the SharePoint item (Create Item action) and then the second part updates that item to set the 'AllDayEvent' flag (Send an HTTP Request to SharePoint).
In the original version of the flow, the create item was using the datepicker selected date with no additional formatting from the PowerApps collection. The calendar item was created successfully, but had a random time in each item. The update step (Send and HTTP Request to SharePoint) errors out with the error:
"error": {
"code": 502,
"source": "flow-apim-msmanaged-na-westus2-01.azure-apim.net",
"clientRequestId": "5ec2029c-f09f-4aee-84aa-1a63018c237d",
"message": "BadGateway",
"innerError": {
"message": "Invalid date/time value.\n\nA date/time field contains invalid data. Please check the value and try again.\r\nclientRequestId: 5ec2029c-f09f-4aee-84aa-1a63018c237d\r\nserviceRequestId: a6592d9f-6035-a000-9fa2-c271745bb65f",
"status": 502,
"errors": [
"-2130575332",
"Microsoft.SharePoint.SPException"
]
}
}
So I tried formatting the date coming out of PowerApps differently and that causes the create item step to fail.
Not sure what I need to do for it to see the date/time as valid.