Skip to main content

Accounts service: taunus-accountsd

Keeps the online accounts, syncs calendars every 15 minutes into a local cache, and answers assistant questions. Secrets never leave the service: clients see a public view of each account (kind, name, calendars).

  • Socket: $XDG_RUNTIME_DIR/taunus-accountsd.sock, JSON lines.
  • Accounts: ~/.config/taunus/accounts.json (mode 600).
KindServiceSign-in
icloudiCloud calendars (CalDAV)Apple ID, app-specific password
caldavany CalDAV serverURL, user, password
googleGoogle Calendar (read-only)OAuth in a private web view
icscalendar linkURL
microsoftOutlook / Exchange Onlinedevice code (Microsoft Graph)
homeassistantHome AssistantURL, long-lived token
claudeClaude (Anthropic API)API key

State​

On connecting and after each change:

{"accounts": [ … ], "login": null, "syncing": false}

After a sync: {"events_changed": true}.

Requests​

An optional "rid" is echoed in the reply as {"reply": rid, …}.

RequestReply
{"add": {"kind", "name", "url", "user", "secret", "model"}}{"added": id} or {"error": …} (the account is checked first)
{"remove": id}
{"calendar": {"account": id, "cal": id, "on": bool}}show or hide a calendar
{"sync": true}sync now
{"events": {"from": ms, "to": ms}}{"events": [ … ]}
{"login": "microsoft" | "google" | "cancel"}progress in the state's login
{"ask": "question"}{"answer": "…"} or {"error": …}
{"forget": true}start a new assistant conversation

An event: {"account", "cal", "uid", "title", "location", "start_ms", "end_ms", "all_day", "color"}.

The assistant​

ask goes to Claude when a Claude account exists (with tools for the calendar, the clock, the smart home and web search), else smart-home commands go to Home Assistant's conversation agent.

//2bi: events can be created and changed through the service (CalDAV PUT, Graph, Google), not only read.