how to create the outlook calendar event and how to integrate to calendar component

load(
local!viewType:"WEEK",
local!selectedEvent,
local!currentDate:todate("10/23/2020"),
local!events:{
{
id: "2",
calendarId: "1",
title: "Work conference",
category: "time",
start: "2020-10-26T09:00:00.000Z",
end: "2020-10-26T10:00:00.000Z",
location: "Downtown",
attendees: "Simple list: Mary and Joe",
body: "Appian conference."
},
{
id: "3",
calendarId: "1",
title: "team meeting",
category: "time",
start: "2020-10-27T06:30:00.000Z",
end: "2020-10-27T13:30:00.000Z",
location: "1234 Main Street",
attendees:{"Array of values: ","Mary","Sue"},
body: "Appian conference."
},
{
id: "4",
calendarId: "1",
title: "code review",
category: "time",
start: "2020-10-29T01:00:00.000Z",
end: "2020-10-29T03:00:00.000Z",
location: "Jim's House",
body: "Appian conference."
},
{
id: "5",
calendarId: "1",
title: "Hackthon meeting",
category: "time",
start: "2020-01-30T09:30:00.000Z",
end: "2020-01-30T10:30:00.000Z",
location: "Swimming pool",
attendees:"Mary, John, and Sue",
body: "Need to do 10 laps"
}
},
a!sectionLayout(
contents:{
a!columnsLayout(
columns:{
a!columnLayout(
contents:{
a!buttonArrayLayout(
buttons:{
a!buttonWidget(
label:"Month",
value:"MONTH",
saveInto:local!viewType,
style:if(local!viewType="month","PRIMARY","SECONDARY")
),
a!buttonWidget(
label:"Week",
value:"WEEK",
saveInto:local!viewType,
style:if(local!viewType="week","PRIMARY","SECONDARY")
),
a!buttonWidget(
label:"All Day",
value:"DAY",
saveInto:{
local!viewType,
a!save(local!currentDate,today())
},
style:if(local!viewType="day","PRIMARY","SECONDARY")
)
}
)
}
),
a!columnLayout(
contents:{
a!buttonArrayLayout(
buttons:{
a!buttonWidget(
label:"Previous Month",
value:-7,
saveInto:a!save(
local!currentDate,
eomonth(local!currentDate,-1)
)
),
a!buttonWidget(
label:"Next Month",
value:7,
saveInto:a!save(
local!currentDate,
eomonth(local!currentDate,1)
)
)
},
showWhen:local!viewType="month",
align:"END"
),
a!buttonArrayLayout(
buttons:{
a!buttonWidget(
label:"Previous Week",
value:-7,
saveInto:a!save(
local!currentDate,
local!currentDate+save!value
)
),
a!buttonWidget(
label:"Next Week",
value:7,
saveInto:a!save(
local!currentDate,
local!currentDate+save!value
)
)
},
showWhen:local!viewType="week",
align:"END"
),
a!buttonArrayLayout(
buttons:{
a!buttonWidget(
label:"Previous Day",
value:-1,
saveInto:a!save(
local!currentDate,
local!currentDate+save!value
)
),
a!buttonWidget(
label:"Next Day",
value:1,
saveInto:a!save(
local!currentDate,
local!currentDate+save!value
)
)
},
showWhen:local!viewType="day",
align:"END"
)
}
)
}
),
a!columnsLayout(
columns:{
a!columnLayout(
contents:{
calendarDisplayField(
viewType:local!viewType,
dateContext:local!currentDate,
detailDateFormat:"YYYY-MM-DD",
useDetailPopup: true,
events:local!events,
selectedEvent: local!selectedEvent
)
}
)
}
),
a!paragraphField(
label:"Selected Event",
value:local!selectedEvent,
saveInto:local!selectedEvent
)
}
)
)

  Discussion posts and replies are publicly visible