Skip to content

Agent integrations

HAR’s runtime is agent-agnostic. Integrations teach an agent when and how to use the same repository-owned harness.

HAR provides three workflows:

Workflow Purpose
/setup-har Install HAR, choose a profile, initialize, adapt, prove, and commit a harness
/har-wt Launch a slot, work only in its worktree, and verify the task
/har-maintain inspect drift, apply maintenance updates, finalize, and re-verify

Targets are auto-detected during init and maintain, or selected explicitly:

Terminal window
har agents install --claude --cursor
har agents install --codex
har agents install --agents claude,cursor,codex
har agents remove --claude

Locations differ by agent:

  • Claude Code: .claude/skills/<name>/SKILL.md in the repository;
  • Cursor: .cursor/commands/<name>.md in the repository;
  • Codex: ~/.codex/prompts/ globally, because Codex has no repository prompt folder.

Managed files carry a HAR header. maintain refreshes files that remain managed and preserves files whose header was removed. --force explicitly overwrites modified managed targets.

HAR can scaffold .cursor/rules/har-workflow.mdc, which injects launch-before-edit and verify-before-done guidance into every Cursor agent session:

Terminal window
har env maintain --cursor-rule
har env maintain --no-cursor-rule

An existing rule is refreshed on maintain.

Optional enforcement blocks Claude Code edit tools in the main checkout:

Terminal window
har hooks install --claude
har hooks uninstall --claude

This writes a repository guard script and a PreToolUse entry in .claude/settings.json. Edits inside HAR session worktrees pass. The HAR_SKIP_WT_GUARD=1 bypass is intended for deliberate human use.

Any MCP client can discover HAR’s generic tools for initialization, preflight, launch, recovery, stages, verification, status, logs, completion, teardown, artifacts, runs, and Mission Control.

MCP is the preferred interface in agents because it returns structured results and persists run history without requiring the model to interpret shell output.