Everything goes over one SSH connection per machine, with the key the app makes on the phone. Nothing runs on a server of ours. This page is for developers; what the user sees is in the user guide.
- Classic herdr: the app reaches herdr's socket API through
direct-streamlocal, falling back toherdr remote-api-bridge. herdr answers one request per connection, so each call opens a new channel;events.subscribekeeps one open for live updates. Terminals useherdr terminal session control. - herdr-core (the Herdr desktop app's runtime, also on Windows): one
herdr-core connectchannel per machine. How it is found and how its model maps onto the screens:HERDR_CORE.md.
A machine may run both; the machine screen shows both in one list.
- Shepherdr 3 (
core/…/shepherdr/): the app forwards a port to the service on the machine's127.0.0.1:7788(or usescurlandbunthere when the SSH server forwards nothing), with the token from~/.herdr/shepherdr/token. It reads what the 3.1 web app reads (web/shared/types.ts). The tests use 3.1.2's own answers, scrubbed (core/src/test/resources/shepherdr/). - simple-herdr-projects (
core/…/shp/):shp list --json,shp show,shp accept --yesandshp sayover SSH, and the worker's terminal withhc read. No service, port or token; the app polls while a screen is open.
Detect picks shp where it is on the PATH, else Shepherdr 3.
An agent's chat and timeline are read from its own session files over SSH: Claude Code's (~/.claude/projects), Codex's (~/.codex/sessions), pi's and omp's (~/.pi/agent/sessions). Large sessions are pruned on the machine with Python 3 before they are sent, and only the newest part of a very long one is read.
Pictures and voice messages are copied to ~/.cache/herdr-android/uploads/ on the machine and named to the agent as @path, since herdr passes agents only text and keys.
Code is read with git and the shell. Git runs with GIT_OPTIONAL_LOCKS=0, so reading changes nothing, not even the index. Pull requests are read and reviewed with the machine's gh (core/…/github/); what you write goes to gh api on its input, never on a command line.
herdr.doc/2 documents are read from ~/.herdr/docs with ls, stat and head (core/…/docs/). The list reads only each file's head; an open document is read again when its file changes.
The app copies small Python 3 scripts to a machine when a feature needs them, unless Allow host scripts is off for it. Each is one file using only the standard library, with a version: line the app compares before replacing it.
herdr-push: notifications, Live Updates, health readings, the brief's journal, and pairing.herdr-usage: AI providers' usage and limits, with the keys and logins already on the machine. Nothing comes to the phone but the numbers.herdr-logins: agent CLIs' logins, run with their own commands.herdr-app-build: builds the app's updates (RELEASING.md).