Interface AddCalendarEventInput

Hierarchy

  • AddCalendarEventInput

Properties

title: string

Event title, shown as the event name in the calendar UI.

startDate: string

Event start, as an ISO 8601 date string.

endDate?: string

Event end, as an ISO 8601 date string.

Default

startDate plus one hour, or the end of the day when allDay is true

allDay?: boolean

Marks the event as lasting the whole day, so the calendar UI hides the time fields.

When no endDate is given, the event covers the whole day of startDate.

Default

false
location?: string

Event location.

notes?: string

Free-text notes or description for the event.

recurrenceRule?: string

Recurrence rule as an RFC 5545 RRULE value, without the RRULE: prefix.

FREQ is required and accepts DAILY, WEEKLY, MONTHLY and YEARLY. INTERVAL, COUNT, UNTIL, BYDAY, BYMONTHDAY, BYMONTH, BYWEEKNO, BYYEARDAY and BYSETPOS are supported, subject to the combinations the calendar allows — BYMONTHDAY only applies to a monthly rule, BYMONTH/BYWEEKNO/BYYEARDAY only to a yearly one, BYDAY to anything but daily, and an ordinal weekday such as 2MO is not valid on a weekly rule.

On iOS a rule that cannot be represented is rejected with calendar.recurrenceRule.invalid rather than applied with the offending part dropped, since a dropped part usually yields a plausible but wrong schedule. This includes parts that are merely redundant, such as BYDAY on a daily rule. On Android the rule is handed to the calendar app as given, which decides what it accepts, so a rule iOS rejects may still be accepted there.

Example: "FREQ=WEEKLY;COUNT=10", "FREQ=WEEKLY;BYDAY=MO,WE", "FREQ=MONTHLY;BYDAY=-1FR"

attendees?: string[]

Guest e-mail addresses to prefill.

🚨 Android only: iOS ignores this field, because EventKit does not allow prefilling guests on an event that has not been saved yet.

How the event's time should be treated when other people check the user's schedule.

🚨 Android only: see CalendarEventAvailability.

Default

the calendar's own default

Visibility of the event to other people who can see the calendar.

🚨 Android only: iOS ignores this field, because EventKit exposes no public API for event visibility.

url?: string

A URL to associate with the event.

🚨 iOS only: Android ignores this field, because the calendar insert intent has no documented URL extra.

Generated using TypeDoc