Halyard CLI
The Halyard CLI scaffolds MCP client configs and syncs your coding-session logs back to Halyard as knowledge. For developers who want to wire up multiple clients at once, or feed agent sessions into the knowledge base. It is one on-ramp among several — you can also configure each client by hand from its own page.
Install
Section titled “Install”The package is @halyard/cli and the binary is halyard. Install it globally, or run it once without installing:
npm i -g @halyard/clipnpm dlx @halyard/cliAuthenticate
Section titled “Authenticate”halyard loginlogin runs a browser-based PKCE OAuth flow and writes your credentials to ~/.halyard/credentials.json.
For headless or CI environments, skip the browser flow by setting a token instead:
export HALYARD_TOKEN=sk_halyard_…Scaffold client configs
Section titled “Scaffold client configs”halyard setupsetup (alias init) writes the MCP server config for each client it supports:
| Client | What setup writes |
|---|---|
| Claude Code | Registers the halyard HTTP server |
| Cursor | Upserts halyard in .cursor/mcp.json, preserving existing servers |
| Codex | Adds [mcp_servers.halyard] to ~/.codex/config.toml |
Preview the changes without writing anything:
halyard setup --dry-runSync session logs
Section titled “Sync session logs”halyard syncsync discovers coding-session logs in ~/.claude/projects/ and ~/.codex/sessions/, then ingests them as knowledge. It tracks what it has already sent in ~/.halyard/sync-state.json so re-runs only pick up new sessions.
Flags:
--provider— limit the sync to one provider’s sessions--dry-run— show what would be ingested without sending anything
Push a single session
Section titled “Push a single session”halyard push <file> --provider <provider> --session-id <id>push ingests one session file directly. Both sync and push send to the ingest endpoint /api/v1/sessions/ingest.
Verify
Section titled “Verify”After halyard setup, open a configured client and ask the agent to identify you:
Use Halyard to tell me who I am.Expect a whoami call returning your user and organization. If the tools do not appear, see Troubleshooting.