Create Calendar Event (Outlook)
This service task creates a calendar event in a user's Outlook calendar via the Microsoft Graph API. It supports attendees, location, online meetings (automatic Teams link), reminders, and all-day events.
Benefit: Meetings, deadlines, and follow-ups can be scheduled automatically as part of a business process — no manual calendar entry needed.
Prerequisites
A Microsoft Entra ID (Azure AD) App Registration is required with:
- Application permission:
Calendars.ReadWrite - Admin consent granted for the tenant
The credentials can be stored as Pantarey Secrets and referenced via {{secret:NAME}}.
Input Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
credentials |
Object | Yes | { tenantId, oAuthClientID, clientSecret } — Microsoft Entra ID credentials. |
userId |
String | Yes | User principal name or object ID (e.g. max@contoso.com). |
subject |
String | Yes | Event title. |
start |
String | Yes | Start date/time (ISO format without timezone, e.g. 2026-02-20T09:00:00). |
end |
String | Yes | End date/time (ISO format). |
body |
String | No | Event description / notes. |
bodyType |
String | No | text or html. Default: text. |
attendees |
Array | No | List of attendees — either email strings or objects { email, name?, type? }. Type: required, optional, or resource. |
location |
String / Object | No | Room or location name. |
isOnlineMeeting |
Boolean | No | If true, a Teams meeting link is generated automatically. |
reminderMinutes |
Number | No | Reminder before the event (in minutes). |
isAllDay |
Boolean | No | If true, creates an all-day event. |
timeZone |
String | No | Timezone for start/end. Default: Europe/Berlin. |
Example Input
{
"credentials": {
"tenantId": "{{secret:MS_TENANT_ID}}",
"oAuthClientID": "{{secret:MS_CLIENT_ID}}",
"clientSecret": "{{secret:MS_CLIENT_SECRET}}"
},
"userId": "max@contoso.com",
"subject": "Onboarding meeting",
"start": "2026-02-20T09:00:00",
"end": "2026-02-20T10:00:00",
"body": "Welcome to the team! Please bring your laptop.",
"attendees": ["anna@contoso.com", "tom@contoso.com"],
"location": "Room Berlin",
"isOnlineMeeting": true,
"timeZone": "Europe/Berlin"
}
Output
| Field | Type | Description |
|---|---|---|
eventId |
String | The ID of the created event. |
subject |
String | The event subject. |
start |
Object | { dateTime, timeZone }. |
end |
Object | { dateTime, timeZone }. |
webLink |
String / null | URL to open the event in Outlook Web. |
onlineMeetingUrl |
String / null | Teams meeting join URL (if isOnlineMeeting was true). |
createdDateTime |
String | ISO timestamp of when the event was created. |
Example Output
{
"eventId": "AAMkAGI2...",
"subject": "Onboarding meeting",
"start": { "dateTime": "2026-02-20T09:00:00", "timeZone": "Europe/Berlin" },
"end": { "dateTime": "2026-02-20T10:00:00", "timeZone": "Europe/Berlin" },
"webLink": "https://outlook.office365.com/owa/?itemid=...",
"onlineMeetingUrl": "https://teams.microsoft.com/l/meetup-join/...",
"createdDateTime": "2026-02-14T10:30:00Z"
}
Use Cases
- Onboarding: Automatically schedule a welcome meeting when a new employee process starts.
- Approval follow-ups: Create a review meeting after an approval is granted.
- Deadlines: Add a calendar reminder for a contract renewal or payment due date.
- Interviews: Schedule candidate interviews as part of an HR process.
- Teams meetings: Generate a Teams meeting link automatically by setting
isOnlineMeeting: true.