harness-hook

Projects canonical hook definitions to Claude Code, Copilot, and Codex configs.

12|Updated Feb 6, 2026
One-click install
npx skills add https://github.com/madebywild/agent-harness --skill harness-hook
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: harness-hook
Source: https://github.com/madebywild/agent-harness/tree/main/.claude/skills/harness-hook
Command: npx skills add https://github.com/madebywild/agent-harness --skill harness-hook

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Managing agent lifecycle hooks across multiple providers is complex and error-prone without a single source of truth.

Core Features & Use Cases

  • Canonical hook definitions stored in .harness/src/hooks/<hook-id>.json that can be projected to Claude Code, Copilot, and Codex.
  • Provider-specific outputs generated during npx harness apply, ensuring consistency across environments.
  • Use Case: Define a set of lifecycle events for a deployment workflow and have them automatically transformed into all provider configurations.

Quick Start

Scaffold a new hook with npx harness add hook <hook-id>, edit .harness/src/hooks/<hook-id>.json, and run npx harness apply to generate provider configs.

Frequently Asked Questions about harness-hook

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I manage agent lifecycle hooks across Claude Code, Copilot, and Codex?

Agent lifecycle hooks can be managed across Claude Code, Copilot, and Codex by defining a canonical source of truth in .harness/src/hooks/ that deterministically translates into each provider's specific configuration format.

What's the best way to synchronize hook configurations across multiple coding agents?

Synchronizing hook configurations across multiple coding agents is best handled by storing canonical definitions in JSON files and using an apply command to project them into provider-specific outputs, ensuring consistency across environments.

How do I scaffold and deploy a new lifecycle hook for deployment workflows?

To scaffold and deploy a lifecycle hook, run npx harness add hook to generate the JSON definition, edit the file, and execute npx harness apply to translate and deploy the configuration to all supported providers.

Does this hook projection approach enforce structural validation for provider configs?

Yes, hook projection enforces structural validation by checking the canonical shape, events matrix, and handler types during the apply process to satisfy functional requirements before generating provider outputs.

Can I use canonical hook definitions without manually editing each provider's config format?

Yes, canonical hook definitions stored in .harness/src/hooks/ are automatically translated into each provider's config format during the apply step, eliminating the need to manually edit individual provider configurations.

Why do I need a single source of truth for agent lifecycle hooks?

A single source of truth for agent lifecycle hooks is needed because managing configurations independently across multiple providers is complex, error-prone, and leads to inconsistencies between different development environments.