I’ve created a demo Nextcloud build(https://try.nextcloud.com/cie7oofe) and enabled the calendar app. Functions like PROPFIND are working via CURL, but I can’t create a new calendar(not a calendar object).
The MKCALENDAR spec doesn’t exist on the server, so I’m using MKCOL based on the RFC5689 spec like so:
<D:mkcol xmlns:D="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav">
<D:set>
<D:prop>
<D:resourcetype>
<D:collection/>
<C:calendar/>
</D:resourcetype>
<D:displayname>New Event XYZ</D:displayname>
</D:prop>
</D:set>
</D:mkcol>
Here’s the full command I’m running:
curl -v --user "admin:admin" -H "Content-Type: application/xml" -X MKCOL "https://try.nextcloud.com/cie7oofe/remote.php/dav/" -d '<?xml version="1.0" encoding="utf-8" ?><D:mkcol xmlns:D="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav"><D:set><D:prop><D:resourcetype><D:collection/><C:calendar/></D:resourcetype><D:displayname>New Event XYZ</D:displayname></D:prop></D:set></D:mkcol>'
And the error response:
<d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
<s:exception>Sabre\DAV\Exception\NotFound</s:exception>
<s:message>Node with name 'root' could not be found</s:message>
</d:error>
Nextcloud version: 60min demo version on try.nextcloud.com
Steps to replicate it:
- Create demo server
- Install calendar app
- Run Curl command via terminal
(This is also cross posted on stackoverflow, in case someone wants to answer it there as well)