Files
email-assistant/openspec/changes/tasktracker-module/specs/tasktracker/spec.md
T

1.4 KiB

hash, date
hash date
tasktracker-module-v1 2026-10-24

TaskTracker Module Spec

Requirement: Module isolation

  • DI: tasktracker/ is top-level dir, self-contained
  • app.py imports only tasktracker.api.router → app.include_router()
  • No direct import radicale for tasks outside tasktracker

Requirement: CRUD operations

Scenario: Create task

  • POST /api/tasks/create (summary, due?, priority?, description?)
  • Returns: reload stub (HTMX) or JSON {ok, uid}

Scenario: Toggle task

  • POST /api/task/{uid}/toggle
  • Radicale: NEEDS-ACTION ↔ COMPLETED
  • Returns: reload stub or JSON

Scenario: Update task summary/due

  • PUT /api/task/{uid}/update {summary, due?}
  • Radicale: GET+PUT SUMMARY/DUE
  • Returns: JSON {ok}

Scenario: Delete task

  • DELETE /api/task/{uid}
  • Soft delete: STATUS:CANCELLED + X-DELETED
  • Returns: JSON {ok}; HTMX: reload stub

Scenario: Set priority

  • PUT /api/task/{uid}/priority {priority: 1-5}
  • Radicale: GET+PUT PRIORITY
  • Returns: JSON {ok}

Requirement: HTML fragments

  • GET /api/tasks/reload → full card HTML (chead + cbody + add-task button + inline edit)
  • GET /api/tasks/new-form → inline create form HTML
  • All fragments use Alpine.js for inline editing, HTMX for submission

Storage

  • Current: webui.radicale module (CalDAV VTODO)
  • Future: own SQLite table (tasks)
  • Switch: replace tasktracker/__init__.py storage import, API unchanged