LibCal feed(s)
Retreive LibCal events as JSON objects. I wrote a Blog Post™ about how this works (tldr: it's pulling the same data as LibCal's calendar widgets).
Note: this is currently only pulling Calendar events, as a JSON feed of library/branch hours already exists. Not too sure how this works with room bookings either.
usage
var libcalEvents = var iid = 123var calendars = 1111 1212
libcalEvents(iid, calendars, callback)
callback(err, events)
will be passed an array of events objects. Note that this
won't be sorted, but will be arranged in an order similar to the calendars
array.
libcalEvents(opts, callback)
with opts
being an object with the following options:
key | value |
---|---|
iid |
the institution's LibApps ID |
calendars |
the id(s) of the calendar requested (use an array for multiples) |
start |
start date for events (either Date object or YYYY-MM-DD string) |
end |
end date for events (either Date object or YYYY-MM-DD string) |
Okay, but what do these events objects look like?
license
MIT