This library requests a calendar object and its events provided by a CalDav server.
Note: This project is under active development. Things may change.
Specify basic configuration:
config =auth:user: 'username'pass: 'password'uri: ''
Fetches the ctag of a calendar. You can use the calendars ctag to see if anything in the calendar has changed.
var rec = config;rec;
You'll get an object, which looks like this:
href: '/calendars/test/holidays/'name: 'Holiday'ctag: '452'
Fetches the etags of a all events. You can use the events etags to see if an event has changed.
You'll get an array of objects, which looks like this:
ics: '/calendars/test/holidays/6151613161614616.ics'etag: 'fc46dd304e83f572688c68ab63816c8f'ics: '/calendars/test/holidays/6816189165131651.ics'etag: '8d59671ba294af1de0e0b154a8ea64c2'
Fetches events with its data/details.
events has to be an array with objects, which contain an ics attribute. The ics attribute has to look like the ones we get with
var events =ics: '/calendars/user/calendar_name/12345.ics'ics: '/calendars/user/calendar_name/67890.ics';rec;
Output should be something like this:
ics: '/calendars/test/holidays/1234564316516.ics'etag: 'fc46dd304e83f572688c68ab63816c8f"'data:title: 'Holiday: John Doe'start: Wed Jul 08 2015 00:00:00 GMT+end: Sat Aug 08 2015 00:00:00 GMT+createdAt: Wed Mar 04 2015 18:09:02 GMT+
Fetches all events of the given calendar with data/details.
Fetch all events which occur between
end (have to be valid iCal Dates). If you leave
end out, you'll get all events from today.
var start = ;var end = ;return rec;