Write an interface to a calendar program (Sun calendar manager (cm), CDE calendar, schedule+, vcalendar compliant, Microsoft Outlook, ...) that automatically forwards or answers calls ("I'm in a meeting until 4:30", "I'm on vacation until August 26"). Allow user to define keywords that govern behavior, e.g., "private" may disable forwarding calls. Use existing privacy indications (e.g., for Sun's cm "Show Time and Text", "Show Time Only", "Show Nothing") to govern detail to be provided, but allow configuration based on user groups. For example, the user might configure the application so that all callers from cs.columbia.edu are shown time only, while a select group of people identified by their email addresses are shown full details. Everybody else is shown nothing ("available" and "not available"). You could use the Netscape addressbook to look up forwarding details. (For example, "meeting at Hilton, San Francisco" would look up phone number for forwarding.)
For the Sun calendar manager (cm), the file is stored in /usr/spool/calendar/callog.$USER. The program cm_lookup -c user@host can be used to retrieve calendar information from within a program, but the output requires some amount of parsing. You may also be able to reverse-engineer the Sun RPC format used.
The file format has the following fields:
(add date key: key what: first line details: details duration: seconds period: period ntimes: # of times repeated author: email address tags: ? apptstat: active privacy: private|semiprivate|public attributes: notificationThe period can be: single, daily, weekly, biweekly, monthly, yearly, tueThur (Tuesday and Thursday), monThruFri, monWedFri,
The amount of data shown to callers should be configurable based on who is calling, for example:
calendar entry | Retry-After | show text of appointment |
---|---|---|
public | * | *columbia.edu |
semiprivate | * | @cs.columbia.edu |
private | friend@aol.com | wife@earthlink.net |
The program should work with sipc and as a cgi script for sipd.
Your program should be able to deal with overlapping appointments. For example, if the user is traveling to LA and has a meeting there, indicating the end of the meeting may not be particularly interesting, but rather the time to call back would be the time of return from the trip. In that case, there would be two entries in the calendar:
The Sun calendar file format has only a single entry for a set of repeating appointments, so you have to compute all repeats.
Consider parsing the calendar entry to understand header fields, e.g., a Contact: line would indicate the appropriate forwarding location.
For the Sun calendar manager (cm), the calendar files are stored in /var/spool/calendar.
The application should be called as
The application should return messages in the format of SIP cgi responses, for example:
SIP/2.0 480 Meeting with John Doe Contact: j.doe@cs.bar.edu Retry-After: Mon, 9 Feb 1998 17:37:17 GMT Content-Length: 0If there is currently no meeting scheduled, return 200 OK.