Quick Start
Learn how to install, configure authentication (Basic, OAuth), and initialize your first DAV client in less than 60 seconds.
Get started quickly with comprehensive guides and API references:
Quick Start
Learn how to install, configure authentication (Basic, OAuth), and initialize your first DAV client in less than 60 seconds.
CalDAV APIs
Discover calendar collections, query events by time range, handle recurring events, and manage attendees.
CardDAV APIs
Connect to remote address books, retrieve and parse vCards, and perform atomic contact updates.
Smart Calendar Sync
Production-ready architectural guide for bi-directional remote-to-local sync with CTAGs and delta tokens.
Cloud Providers
Setup instructions and quirk workarounds for Apple iCloud, Google Calendar, Fastmail, Nextcloud, and Zoho.
Interactive Converter
Real-time playground to convert and inspect WebDAV XML request bodies and normalized response structures.
Install tsdav using your preferred package manager:
pnpm add tsdavnpm install tsdavyarn add tsdavbun add tsdavimport { createDAVClient } from 'npm:tsdav';Connecting to Apple iCloud CalDAV:
import { createDAVClient } from 'tsdav';
const client = await createDAVClient({ serverUrl: 'https://caldav.icloud.com', credentials: { username: 'YOUR_APPLE_ID', password: 'YOUR_APP_SPECIFIC_PASSWORD', }, authMethod: 'Basic', defaultAccountType: 'caldav',});
// Discover all remote calendarsconst calendars = await client.fetchCalendars();console.log(`Found ${calendars.length} calendars:`, calendars.map((c) => c.displayName));
// Fetch all calendar eventsconst events = await client.fetchCalendarObjects({ calendar: calendars[0],});console.log(`Fetched ${events.length} calendar events.`);Universal Portability
Designed with zero Node-only globals (fs, net, stream). Works out of the box in browsers, Node.js, Cloudflare Workers, Electron, Bun, and Deno.
Delta Sync & CTAGs
Native support for RFC 6578 sync-collection reports and WebDAV getctag headers for instant, low-bandwidth delta updates.
Real Provider Quirks Handled
Pre-configured normalization routines for Google’s UID renames, Apple’s custom namespaces, and Nextcloud’s deletion quirks.
AI-Ready Documentation
Provides structured /llms.txt and plain-text feeds optimized for ingestion by Cursor, Claude, and custom LLM workflows.