Premise
In this post we’ll discuss how to create a new event in the OOTB Events list in modern SharePoint Online Communication sites.
Solution
There’s no direct action card in MS Power Automate to create an event. However, we can use the standard ITEMS API to create a new list item in the Events list. While doing so, we just need to ensure that we’re updating all the required metadata values correctly.
Since, we’ll be using the SharePoint Rest API, the same approach can also be used in other custom solutions as well, to create Events. For ex., SPFx, Add-Ins, etc.
MS Power Automate

Code Snippet [Body]
{
'__metadata': {
'type': 'SP.Data.EventsListItem'
},
'fAllDayEvent': 'false',
'EventDate': '@{variables(' startDate ')}', //addDays(utcNow(),2)
'EndDate': '@{variables(' endDate ')}', //addHours(addDays(utcNow(), 2),2)
'Title': 'Test Event from Flow: PK',
'Category': 'Meeting',
'Location': 'Pune, India',
'Geolocation': {
'__metadata': {
'type': 'SP.FieldGeolocationValue'
},
'Latitude': 18.5204,
'Longitude': 73.8567
},
'Description': '<b>Agenda</b><br/><br/>Test event created by <b>Piyush</b> from MS Flow' //supports rich text format
}
The solution can be divided in to the following 2 sections:
- Flow Header
- Flow Body
Flow Header
Entity | Value | Usage |
---|---|---|
Site Address | The URL of the site. | |
Method | POST | Fixed |
Uri | /_api/web/lists/getByTitle(‘Events’)/items | Fixed. Please ensure that the name of our list is ‘Events’ only. Otherwise, use your custom list name. |
Content-Type | application/json;odata=verbose | Indicates we’re sending the data in JSON format |
Accept | application/json;odata=verbose | Indicates we’re requesting to receive the data in JSON format. [Optional] |
Flow Body
Property | Value | Usage |
---|---|---|
‘__metadata’ | ‘type’: ‘SP.Data.EventsListItem’ | This value is usually fixed for all Events list. But it’s always better to double check its value. You can find more info regarding the same here. |
fAllDayEvent | false | Is all day event |
EventDate | 2020-05-04T14:31:04.6240863Z | Start date of your event. It accepts the value in ISO 8601 format. Here, I’ve just used the formula, addDays(utcNow(),2) |
EndDate | 2020-05-04T16:31:04.9053567Z | End date of your event. I’ve added couple of hours to the EventDate. Indicating that our event duration is of 2 hours. addHours(addDays(utcNow(), 2),2) |
Title | Title of your event | |
Category | Meeting category. [Optional] | |
Location | Pune, India | [Optional] |
Geolocation | { ‘__metadata’: {‘type’: ‘SP.FieldGeolocationValue’}, ‘Latitude’: 18.5204, ‘Longitude’: 73.8567 } | Maps co-ordinates of the meeting location. [Optional] |
Description | Meeting agenda. It supports rich text formatting. | |
On running the above flow, a new event will be created as per the info provided.

Key Takeaways
- Events list is just like any other SharePoint list.
- We’re using the standard SharePoint REST API to create a new entry into this list.
- All the time values provided [EventDate & EndDate] are supposed to be in ISO 8601 format only.
- The date values should be entered equivalent to their UTC date/time only.
- I’m using the default, Geolocation field. However, in order to create a map view, please ensure that all the prerequisites are satisfied first.
Hi. thanks for sharing this. I am trying to create a flow to add an entry in the sharepoint Events list when a new item is added into a customized list. I got following error when follow your example to create a flow:
{“odata.error”:{“code”:”-1, Microsoft.SharePoint.Client.InvalidClientQueryException”,”message”:{“lang”:”en-US”,”value”:”The expression \”web/lists/getByTitle(\u2018Events\u2019)/items\” is not valid.”}}}
clientRequestId: a696aa6d-3172-4267-a3d3-41310e9db592
serviceRequestId: c0138e9f-a0d9-2000-7810-b7a7efb520c1
How can I fixe this?
thanks
Jim
LikeLike
Copying from this page uses incorrect quotes. Replace with this: \u2018Events\u2019 with ‘Events’ (Events surrounded by single quotes)
LikeLike
How can I create an event that can be automatically managed with Sharepoint, Power Automate, or Power Apps? I teach several different classes and would like to set up a flow that allows users to register, without overfilling the slots in my course. Could you help me?
LikeLike