What an ICS calendar feed is, how LeaveSync generates them, and how to subscribe in Outlook, Google Calendar, and Apple Calendar.
An ICS feed (also called a calendar subscription or iCalendar feed) is a URL that calendar applications can subscribe to. When the data behind the URL changes, the calendar app fetches a fresh copy and updates the events it shows.
The format is standardised in RFC 5545. Every major calendar application supports it: Outlook, Google Calendar, Apple Calendar, and many others.
LeaveSync generates one ICS feed per person. The feed contains that person's:
Feeds are generated at request time and cached. When leave is approved, declined, or cancelled, the cache is invalidated and the feed is regenerated on the next request.
Each event in the feed has a stable, deterministic UID. This ensures that when leave is updated (for example, dates are changed), the calendar app updates the existing event rather than creating a duplicate.
UIDs are generated from a combination of the person ID, the availability record ID, and the feed ID. They are consistent across cache invalidations and token regenerations.
Feed URLs are not guessable. Each URL contains a signed token that is specific to the person and the feed configuration. If a URL is shared outside the intended audience, the token can be revoked and regenerated. Existing calendar subscriptions using the old URL will stop receiving updates.
Tokens are never stored in plaintext. Only a cryptographic hash is persisted.
Note: Google Calendar refreshes subscribed calendars every 12 to 24 hours.