No description
Find a file
2026-03-02 18:25:35 +03:00
src feat(caldav): extract hashtags from summary for nodex feed compatibility in issue creation 2026-03-02 18:25:35 +03:00
test test(caldav): cover create-on-put flow for new reminder tasks 2026-02-27 18:13:17 +03:00
.dockerignore chore: add docker packaging and document full multi-principal signer setup 2026-02-24 15:40:15 +03:00
.gitignore docs(config): add HTTPS setup guidance and ignore local runtime files 2026-02-25 16:55:17 +03:00
config.example.yaml feat(caldav): add single-list mode by disabling auto pubkey calendars 2026-02-26 16:40:37 +03:00
docker-compose.yml chore: add docker packaging and document full multi-principal signer setup 2026-02-24 15:40:15 +03:00
Dockerfile chore: add docker packaging and document full multi-principal signer setup 2026-02-24 15:40:15 +03:00
package-lock.json fix(nostr): use ws implementation and valid relay subscriptions 2026-02-25 16:55:26 +03:00
package.json fix(nostr): use ws implementation and valid relay subscriptions 2026-02-25 16:55:26 +03:00
README.md docs(config): add HTTPS setup guidance and ignore local runtime files 2026-02-25 16:55:17 +03:00

nostr-caldav-bridge (JS)

Nostr Relay ↔ CalDAV bridge with two-way status sync for NIP-34 git issues.

Implemented Scope

  • Nostr subscriptions:
    • kind 1621 issues
    • status kinds 1630-1633
    • comment kind 1622
  • NIP-42 relay auth support for read/write operations
  • NIP-46 bunker signer support (bunker_url) plus local key signer fallback
  • SQLite state store with:
    • sync token tracking
    • ETag/SEQUENCE conflict handling
    • sync log
  • CalDAV/WebDAV endpoints:
    • principal collection discovery
    • per-calendar collection listing
    • object GET/PUT/DELETE behavior (DELETE intentionally unsupported)
    • REPORT handling for sync-collection and calendar-query
  • Multi-principal support with per-principal credentials and visibility filters
  • Automatic per-pubkey calendars (one calendar per tracked pubkey)
  • Configurable filtered calendars per principal (labels/status/text/pubkeys)
  • VTODO mapping for issues, labels, status, description, and nevent URL back-links
  • CalDAV -> Nostr writeback on status transitions
  • Unit/integration test suite via node:test

Run

cp config.example.yaml config.yaml
npm install
npm start

Server defaults to http://localhost:5232.

Apple Reminders Setup (HTTPS via Caddy)

Apple account verification is most reliable over HTTPS on port 443.

  1. Point a DNS hostname (example: caldav.example.com) to your server IP.
  2. Update config.yaml:
    • caldav.host: "::"
    • caldav.base_url: "https://caldav.example.com"
  3. Edit Caddyfile and replace caldav.example.com with your real hostname.
  4. Run bridge and Caddy:
npm start
caddy run --config ./Caddyfile
  1. In Apple Reminders CalDAV account:
    • Server: caldav.example.com
    • Username/password: values from config.yaml
    • SSL: on (default)

Test

npm test

CalDAV Endpoints

  • PROPFIND /.well-known/caldav
  • PROPFIND /calendars/{user}/
  • PROPFIND /calendars/{user}/{calendarId}/
  • GET /calendars/{user}/{calendarId}/{uid}.ics
  • PUT /calendars/{user}/{calendarId}/{uid}.ics
  • DELETE /calendars/{user}/{calendarId}/{uid}.ics (returns 405)
  • REPORT /calendars/{user}/{calendarId}/

Signer Modes

nostr.private_key:

  • nsec1...
  • 64-char hex private key

nostr.bunker_url:

  • NIP-46 bunker URL/identifier
  • when set, bunker mode is used and local key mode is ignored

If neither is set, CalDAV status changes are stored locally but Nostr publish is skipped.

Docker

Build and run with Docker Compose:

docker compose up --build

The container expects /data/config.yaml (mapped from local config.yaml) and stores DB under mounted /data.