0

After connecting to a CalDAV server, you can query to see which services it supports. For example, after Lightning connects to a CalDAV server, it will only allow you to create Task objects if that server advertises Task support.

Unfortunately, some servers (e.g. AppSuite, Yahoo) do support Tasks, but apparently do not correctly advertise the fact, and so strict PIM clients (e.g. Lightning) will not talk Tasks with them.

How (exactly) should CalDAV do this?

I have read https://wiki.wocommunity.org/display/~probert/CalDAV+and+CardDAV+handshake which explains the CalDAV handshake and connectivity, and identifies the DAV features list returned by the OPTIONS call after connecting. Our CalDAV server returns the following list: 1, 2, 3, access-control, calendar-access, addressbook, extended-mkcol, calendar-auto-schedule, calendar-schedule, calendarserver-sharing, calendarserver-principal-search, calendarserver-principal-property-search, calendarserver-private-comments, extended-mkcol, calendar-managed-attachments

However, I cannot find anywhere an exhaustive list of standard feature names, nor can I find out which name is expected for Tasks to be supported.

Can anyone shed some light on this?

Steve Shipway
  • 3,754
  • 3
  • 22
  • 39

1 Answers1

3

The capabilities are held in the supported-calendar-component-set attribute of any given calendar. If this attribute is not set then it should be assumed to support everything.

To get the component set, use this (with the correct calendar URL and authentication):

PROPFIND https://myserver/caldav/url/12345 <?xml version="1.0" encoding="UTF-8"?> <A:propfind xmlns:A="DAV:"> <A:prop> <C:supported-calendar-component-set xmlns:C="urn:ietf:params:xml:ns:caldav"/> </A:prop> </A:propfind>

this returns

<D:multistatus> <D:response> <D:href>/caldav/3382/</D:href> <D:propstat> <D:prop> <supported-calendar-component-set> <CAL:comp name="VEVENT"/> </supported-calendar-component-set> </D:prop> <D:status>HTTP/1.1 200 OK</D:status> </D:propstat> </D:response> </D:multistatus>

In the supported-calendar-component-set section, look for VEVENT (supports calendar events), VTASK (supports tasks), VJOURNAL, etc etc. So in the example above, Calendar events are supported, but not Tasks.

Steve Shipway
  • 3,754
  • 3
  • 22
  • 39