Add public/private calendars, full iCal support, and iCal URL import
- Public/private: toggle is_public via PUT /calendars/{id}; generate/clear
public_token and return ical_url when public
- Public feed: GET /cal/{token}/feed.ics (no auth) for subscription in
Google/Apple/Outlook calendars
- Full iCal export: use golang-ical; VALARM, ATTENDEE, all-day (VALUE=DATE),
RRULE, DTSTAMP, CREATED, LAST-MODIFIED
- Full iCal import: parse TZID, VALUE=DATE, VALARM, ATTENDEE, RRULE
- Import from URL: POST /calendars/import-url with calendar_id + url
- Migration: unique index on public_token, calendar_subscriptions table
- Config: BASE_URL for ical_url; Calendar model + API: ical_url field
- Docs: OpenAPI, llms.txt, README, SKILL.md, about/overview
Made-with: Cursor
This commit is contained in:
18
SKILL.md
18
SKILL.md
@@ -278,10 +278,16 @@ Returns 409 CONFLICT if the slot is no longer available.
|
||||
|--------|----------|-------|-------------|
|
||||
| GET | `/calendars/{id}/export.ics` | calendars:read | Export calendar as ICS file |
|
||||
| POST | `/calendars/import` | calendars:write | Import ICS file (multipart/form-data) |
|
||||
| POST | `/calendars/import-url` | calendars:write | Import from external iCal URL |
|
||||
| GET | `/cal/{token}/feed.ics` | None (public) | Public iCal feed for subscription |
|
||||
|
||||
Export returns `Content-Type: text/calendar`.
|
||||
Export returns `Content-Type: text/calendar` with full RFC 5545 support (VALARM, ATTENDEE, all-day events, RRULE).
|
||||
|
||||
Import requires multipart form with `calendar_id` (uuid) and `file` (.ics file).
|
||||
Import requires multipart form with `calendar_id` (uuid) and `file` (.ics file). Supports VALARM (reminders), ATTENDEE, TZID, VALUE=DATE (all-day).
|
||||
|
||||
Import URL accepts JSON body: `{"calendar_id": "uuid", "url": "https://..."}`. Supports http, https, and webcal protocols.
|
||||
|
||||
Public feed: Set `is_public` to `true` via `PUT /calendars/{id}` to generate an `ical_url`. This URL can be used to subscribe in Google Calendar, Apple Calendar, Outlook, etc.
|
||||
|
||||
### Users
|
||||
|
||||
@@ -375,6 +381,14 @@ When `next_cursor` is `null`, there are no more pages. To fetch the next page, p
|
||||
|
||||
1. `GET /calendars` or `POST /calendars` - ensure target calendar exists.
|
||||
2. `POST /calendars/import` - upload `.ics` file as multipart form data with `calendar_id`.
|
||||
Or: `POST /calendars/import-url` - import from an iCal URL with `{"calendar_id": "...", "url": "https://..."}`.
|
||||
|
||||
### Workflow: Make a calendar publicly subscribable
|
||||
|
||||
1. `PUT /calendars/{id}` with `{"is_public": true}` - generates a public iCal feed URL.
|
||||
2. The response includes `ical_url` (e.g., `https://api.example.com/cal/{token}/feed.ics`).
|
||||
3. Share the `ical_url` - anyone can subscribe to it in their calendar app.
|
||||
4. To revoke: `PUT /calendars/{id}` with `{"is_public": false}` - removes the feed URL.
|
||||
|
||||
## Important Constraints
|
||||
|
||||
|
||||
Reference in New Issue
Block a user