Skip to content

About

iCalendar parsing, recurrence, availability, diffs, and generation as VGI SQL functions in TypeScript

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

20 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Query.Farm

Parse iCalendar Feeds into Events, To-dos & Free Slots in DuckDB

CI Latest release Documentation on Orchard License: MIT vgi worker: query.farm

vgi-ical-typescript · a VGI worker by Query.Farm

Parse iCalendar files into events, to-dos and metadata from SQL. A TypeScript reimplementation of vgi-ical, built on ICAL.js and Luxon.

Documentation and hosting on Orchard: every function and table with runnable examples; run it yourself or let Query.Farm host it

Quick start

SET allow_extension_repositories = 'allowed';

CREATE EXTENSION REPOSITORY IF NOT EXISTS query_farm
    WITH PREFIX 'https://duckdb-extensions.query.farm';

INSTALL vgi FROM query_farm;
LOAD vgi FROM query_farm;

ATTACH 'ical' AS ical (
  TYPE vgi,
  LOCATION 'github-auto://Query-farm/vgi-ical-typescript'
);

-- Inspect one feed in one parse, returning validity, name, event and to-do
-- counts, error and structured diagnostics.
SELECT info.calendar_name, info.event_count, info.todo_count,
  len(info.diagnostics)
FROM (
  SELECT ical.main.ical_inspect(
    array_to_string(
      ['BEGIN:VCALENDAR',
      'VERSION:2.0',
      'PRODID:-//Query Farm//vgi-ical//EN',
      'X-WR-CALNAME:Team Calendar',
      'BEGIN:VEVENT',
      'UID:event-1@query.farm',
      'SUMMARY:Sprint Planning',
      'DESCRIPTION:Plan the next two-week sprint.',
      'DTSTART:20240115T093000Z',
      'DTEND:20240115T103000Z',
      'LOCATION:Conference Room A',
      'STATUS:CONFIRMED',
      'ORGANIZER:mailto:alice@query.farm',
      'ATTENDEE:mailto:bob@query.farm',
      'ATTENDEE:mailto:carol@query.farm',
      'RRULE:FREQ=WEEKLY;BYDAY=MO',
      'SEQUENCE:3',
      'END:VEVENT',
      'BEGIN:VTODO',
      'UID:todo-1@query.farm',
      'SUMMARY:Write release notes',
      'DUE:20240120T170000Z',
      'STATUS:NEEDS-ACTION',
      'PRIORITY:2',
      'PERCENT-COMPLETE:40',
      'END:VTODO',
      'END:VCALENDAR'],
      chr(10)
    )::BLOB
  ) AS info
);

Documentation

VGI: Vector Gateway Interface

Development

make check   # everything CI runs: lint, unit tests, SQL tests, metadata lint

License

MIT, see LICENSE. Written by Query.Farm.

Copyright 2026 Query Farm LLC - https://query.farm

About

iCalendar parsing, recurrence, availability, diffs, and generation as VGI SQL functions in TypeScript

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages