Agent integrations
cc-safety-net connects to coding agents at the point where an agent is about to run a tool. Each connector translates the agent's event into a common tool invocation, sends it through the shared safety guard, and returns a decision in the format that the agent understands. This keeps agent-specific transport separate from the safety rules and audit trail.
Integration model
An integration is the boundary between an agent and the common safety pipeline. The boundary supplies the agent event shape, the tool name and input, the working directory, the session identity, and the response that means “allow” or “block.”
The system follows one path after that boundary, even when agents use different APIs:
flowchart LR
A[Coding agent] --> B[Hook or native connector]
B --> C[Common tool invocation]
C --> D[Runtime safety guard]
D --> E[Agent-specific allow or block response]
D --> F[Audit record]
The common invocation records whether the tool is a shell command or another tool kind. It also carries both the configured project directory and the directory where the tool will run. The guard can therefore apply the same safety decision to commands and file-oriented tool activity without requiring each agent connector to know the safety rules. src/…/invocation.ts• L1-39
Agent entry points
The repository supports two broad connector shapes. Hook connectors run as a command that an agent calls before a tool action. Native connectors run inside an agent's plugin, extension, or package system and receive tool events directly.
Hook connectors
Hook connectors receive structured input from an agent over standard input. The shared pre-tool-use runner validates the event, maps the tool to a common route, and returns the agent's required denial response. Runtime hook metadata defines the public flags, display labels, and descriptions used to select each hook. src/…/pre-tool-use.ts• L7-80, src/…/common.ts• L116-241, src/…/catalog.ts• L25-213
The hook path covers agents that expose a pre-tool event through a command protocol. Claude Code, Codex, Copilot CLI, Cursor, Gemini CLI, Kimi Code, Hermes Agent, Antigravity CLI, Grok Build, Devin CLI, and Factory Droid use agent-specific event fields and response shapes while sharing the same guard path. src/…/catalog.ts• L25-265, src/…/hook.ts• L30-82, src/…/hook.ts• L14-61, src/…/hook.ts• L6-45, src/…/hook.ts• L5-11
Several agents share the PreToolUse event shape. Claude Code uses caller detection when that shape can also represent Codex or Copilot CLI. Copilot CLI parses serialized tool arguments before it creates the common route. Hermes Agent accepts its pre_tool_call event and can apply a request-level workdir inside its trusted root. Kimi Code applies the same containment rule to its command cwd. Cursor maps its pre-tool event through the managed hook command. Antigravity CLI, Grok Build, Devin CLI, and Factory Droid map their own tool and workspace fields into the shared route. The hook layer denies truncated, unresolved, or unsupported requests rather than guessing. src/…/hook.ts• L7-34, src/…/hook.ts• L5-61, src/…/hook.ts• L9-64, src/…/hook.ts• L6-17, src/…/hook.ts• L1-126, src/…/hook.ts• L85-159, src/…/hook.ts• L41-107, src/…/hook.ts• L13-43, src/…/hook.ts• L5-11
References: src/…/pre-tool-use.ts• L7-80 src/…/common.ts• L116-241 src/…/catalog.ts• L25-265 src/…/hook.ts• L7-34 src/…/hook.ts• L5-61 src/…/hook.ts• L9-64 src/…/hook.ts• L6-17 src/…/hook.ts• L1-126 src/…/hook.ts• L30-229 src/…/hook.ts• L14-107 src/…/hook.ts• L6-45 src/…/install.ts• L14-15 src/…/hook.ts• L5-11 src/…/install.ts• L13-14
Native connectors
Native connectors register with an agent's own event system. They inspect the event before execution, return the host's block form when needed, and leave allowed calls to the host. Amp, DeepSeek Harness, OpenClaw, OpenCode, and Pi use this model in the integration layer. src/…/tool-call.ts• L30-49, src/…/guard.ts• L33-54, src/…/plugin.ts• L48-70, src/…/plugin.ts• L41-71, src/…/tool-call.ts• L43-64
The shared plugin adapter gives these connectors one safety boundary. A host-specific extractor builds a common invocation or a failed-closed denial. The adapter evaluates the invocation, writes an audit record when it has a session identity, and converts the result into the host's block or allow form. src/…/plugin-adapter.ts• L17-68, src/…/plugin-adapter.ts• L71-120
Each native host still owns its context rules. Amp needs a usable workspace root and maps shell commands or other tools from its event. DeepSeek Harness maps its session directory and optional command workdir, then supports shell and non-shell tool calls. OpenClaw guards executable calls inside the agent workspace and accepts only known execution hosts. Pi uses its current working directory and session manager. OpenCode checks its tool event before execution and supports both its earlier plugin API and its newer v2 hook API. src/…/tool-call.ts• L51-107, src/…/guard.ts• L56-116, src/…/plugin.ts• L73-137, src/…/tool-call.ts• L67-127, src/…/plugin.ts• L73-172, src/…/v2.ts• L21-80
This split lets a connector use the strongest control point that its host offers. A hook can return a serialized permission decision. A native plugin can reject or block the tool call through the host API. Both forms still use the same guard and denial model.
References: src/…/plugin-adapter.ts• L17-120 src/…/tool-call.ts• L30-140 src/…/guard.ts• L33-116 src/…/plugin.ts• L48-154 src/…/plugin.ts• L41-247 src/…/v2.ts• L21-81 src/…/tool-call.ts• L43-127
Agent control commands
Some native connectors also expose a cc-safety-net command inside the host agent. The command gives the agent shared guidance for explaining blocks, working with rules, managing integrations, and diagnosing protection. OpenCode adds the command to its command surface. Pi sends the same guidance into the current conversation. src/…/plugin.ts• L47-56, src/…/v2.ts• L59-77, src/…/commands.ts• L18-37, src/…/cc-safety-net.ts• L1-9
These commands help an agent operate and explain cc-safety-net. They do not replace the pre-tool decision path. Tool activity still passes through the connector and the common safety guard.
References: src/…/plugin.ts• L47-56 src/…/v2.ts• L59-77 src/…/commands.ts• L18-37 src/…/cc-safety-net.ts• L1-9
Common safety boundary
The common boundary turns different agent payloads into one safety request. Hook adapters validate the event and context before they create the invocation. Native adapters use the same runtime guard after their host-specific extractor has supplied the invocation. src/…/plugin-adapter.ts• L71-120, src/…/common.ts• L133-241
Tool invocation context
The connector must prove where a tool will run before the guard evaluates it. A missing, malformed, or out-of-scope working directory causes a failed-closed denial instead of allowing a decision based on the wrong directory. The context distinguishes the agent's configured root from a request-specific execution directory so relative paths are checked against the place where the tool acts. src/…/invocation.ts• L11-29, src/…/intake.ts• L1-60
Native and hook connectors apply this rule at different points because their hosts expose different fields. Amp, OpenClaw, Hermes Agent, Kimi Code, Cursor, Antigravity CLI, OpenCode, DeepSeek Harness, Devin CLI, and Pi each map a host-specific workspace or working-directory field into the common execution context. src/…/tool-call.ts• L65-107, src/…/plugin.ts• L103-137, src/…/hook.ts• L36-64, src/…/hook.ts• L12-17, src/…/hook.ts• L61-120, src/…/hook.ts• L85-159, src/…/plugin.ts• L119-147, src/…/guard.ts• L66-114, src/…/hook.ts• L40, src/…/tool-call.ts• L78-87
References: src/…/invocation.ts• L11-29 src/…/intake.ts• L1-60 src/…/tool-call.ts• L65-107 src/…/plugin.ts• L103-137 src/…/hook.ts• L36-64 src/…/hook.ts• L12-17 src/…/hook.ts• L61-120 src/…/hook.ts• L85-159 src/…/plugin.ts• L119-147 src/…/guard.ts• L66-114 src/…/hook.ts• L40 src/…/tool-call.ts• L78-87
Safety decision feedback
The runtime boundary calls the shared guard and records the result with the agent and session identity. A denial carries a reason and may include the affected command, segment, rule, tool, or safer next action. Integration adapters then format that denial for the host. src/…/runtime.ts• L21-41, src/…/denial.ts• L1-59, src/…/audit.ts• L31-137
Malformed input and guard failures follow the same safety goal. The connector does not guess when it cannot identify the tool or its execution context. It returns a failed-closed denial and records the failure when a usable session identity exists. The shared native adapter catches errors that would otherwise escape into a plugin host. src/…/plugin-adapter.ts• L43-68, src/…/plugin-adapter.ts• L71-120, src/…/audit.ts• L104-137
References: src/…/runtime.ts• L21-41 src/…/denial.ts• L1-59 src/…/audit.ts• L31-137 src/…/plugin-adapter.ts• L43-120
Caller identity
Some hook payloads share the same shape across agents. The hook layer uses an absolute transcript path when it can verify that the path belongs to one agent's home, Codex, Copilot CLI, or Claude Code area. If the path is missing, ambiguous, malformed, or too costly to resolve, it returns an unknown caller rather than choosing a connector by guesswork. Claude Code environment markers provide a fallback only when no other agent matches. src/…/agent-detection.ts• L7-61
References: src/…/agent-detection.ts• L7-61
Integration catalog
The integration catalog is the shared registry for agent identity and lifecycle metadata. It gives each supported agent one stable ID and connects that ID to its display name, runtime hook details when present, installation artifact type, installation flag, and version probe. DeepSeek Harness uses a package artifact and a bounded package version probe even though it does not expose a runtime hook entry. Native agents such as OpenClaw, OpenCode, Pi, and Amp also remain catalog entries without runtime hook metadata. Cursor has a hook-config installation target and a version probe that can be satisfied by either its main CLI or cursor-agent. src/…/catalog.ts• L1-23, src/…/catalog.ts• L25-31, src/…/catalog.ts• L173-231, src/…/catalog.ts• L250-278
The catalog keeps separate concerns aligned:
| Catalog view | System use |
|---|---|
| Runtime hook metadata | Hook flags, legacy aliases, ordering, and connector selection |
| Installation metadata | Target flags, artifact form, and agent version probe |
| Display names | Human-readable labels for status and audit views |
| Stable integration IDs | Keys shared by hooks, installers, detectors, and audit records |
Runtime hook choices and installation choices derive from this registry. Native agents remain in the same catalog even when they have no runtime hook entry. This lets doctor and installation report the full supported set while hook dispatch exposes only agents with hook metadata. src/…/catalog.ts• L284-317
References: src/…/catalog.ts• L1-31 src/…/catalog.ts• L33-278 src/…/catalog.ts• L284-317
Integration lifecycle
An agent integration has three related lifecycle concerns: install the agent-facing artifact, detect whether the agent and connector are usable, and process tool activity when the agent runs. These concerns share the catalog but use different checks because installation state and runtime state are not the same thing.
Installation and detection
Installation selects a catalog target and applies the artifact form required by the agent. Detection then inspects the agent's own state and reports whether the connector is configured, disabled, not applicable, or not inspected. It avoids treating unreadable configuration as proof that an integration is absent. src/…/context.ts• L6-37, src/…/doctor-types.ts• L11-24
The aggregate detector runs the integration-specific detector for each catalog ID in doctor order. It converts the result into a doctor status so every supported agent has a comparable view of discovery, configuration, and inspection. Devin CLI and Factory Droid use the same managed pre-tool entry model as other hook-config integrations. That model preserves other handlers while detecting drift in the managed command, type, matcher, or timeout. src/…/index.ts• L20-74, src/…/catalog.ts• L284-287, src/…/pre-tool-use-entries.ts• L17-64
The artifact form follows the host. Amp publishes a managed plugin through the user's personal plugin repository and removes obsolete managed copies that could mask it locally. Hermes Agent writes a managed plugin directory. OpenClaw installs a managed extension and verifies that the host loads it. OpenCode selects a compatible plugin API for supported host versions and verifies that the plugin is active. DeepSeek Harness installs the package in its web or Desktop profile and checks that the bundle is enabled. Claude Code, Copilot CLI, Codex, Pi, Cursor, Devin CLI, Factory Droid, and the other hook-based agents inspect or update their host hook configuration rather than using one shared installation path. Cursor preserves unrelated hook entries while installing one canonical pre-tool entry, and its install target can also clean up a separate Cursor marketplace plugin. src/…/install.ts• L251-283, src/…/install.ts• L72-108, src/…/install.ts• L107-159, src/…/install.ts• L62-135, src/…/install.ts• L101-146, src/…/detect.ts• L30-63, src/…/install.ts• L121-169, src/…/detect.ts• L315-386, src/…/detect.ts• L8-42, src/…/detect.ts• L24-61, src/…/install.ts• L70-96, src/…/install.ts• L68-108
The install target chooser probes the agent command before it offers installation. Cursor is available when either cursor --version or cursor-agent --version succeeds. The same choices distinguish an already configured target from a target whose agent CLI is not available, while uninstall choices depend on detected configuration. src/…/choices.ts• L22-100, src/…/catalog.ts• L33-34
Claude Code detection checks both plugin presence and enablement. Cursor detection checks its managed hook for duplicates or drift, then checks whether a native Cursor plugin or an imported Claude Code plugin may also run the same safety check. This lets doctor report duplicate protection instead of treating two active routes as one healthy configuration. src/…/detect.ts• L11-63, src/…/detect.ts• L66-81, src/…/detect.ts• L29-109, src/…/detect.ts• L112-146
DeepSeek Harness detection checks its profiles for the package and its enabled bundle. It reports configured when at least one profile is enabled, disabled when the package is present but no profile enables it, and not-inspected when profile state cannot be read. Installation can target the web profile and an available Desktop profile, but Desktop changes require the app to be closed. src/…/detect.ts• L25-87, src/…/install.ts• L27-65, src/…/install.ts• L101-145
Detection also accounts for host version and config-source rules. Copilot CLI can use user hook files, project hook files, or inline settings when the installed version supports them. Codex reports that hook trust needs a user action. OpenCode checks the configuration form for the host generation in use. Grok Build resolves its hook file from the host's home setting, while Devin CLI and Factory Droid check their own managed pre-tool entries. src/…/detect.ts• L214-313, src/…/detect.ts• L21-40, src/…/detect.ts• L12-54, src/…/install.ts• L20-25, src/…/detect.ts• L14-53, src/…/detect.ts• L11-30, src/…/detect.ts• L6-49
Doctor keeps discovery separate from inspection. A status can show that an agent was detected while its existing state could not be inspected, so health output does not claim that an unreadable integration is absent or ready. Its inspection status distinguishes verified, failed, not-applicable, and not-inspected results. Version probes are bounded and feed the same system report used by installation and detection. src/…/doctor-types.ts• L11-24, src/…/context.ts• L27-37, src/…/system-info.ts• L13-20, src/…/system-info.ts• L162-208
References: src/…/context.ts• L6-37 src/…/index.ts• L20-74 src/…/doctor-types.ts• L11-24 src/…/catalog.ts• L284-317 src/…/pre-tool-use-entries.ts• L17-64 src/…/choices.ts• L22-100 src/…/install.ts• L251-283 src/…/install.ts• L72-108 src/…/install.ts• L107-159 src/…/install.ts• L62-135 src/…/detect.ts• L25-87 src/…/install.ts• L101-146 src/…/detect.ts• L30-81 src/…/detect.ts• L29-146 src/…/install.ts• L121-169 src/…/detect.ts• L214-386 src/…/detect.ts• L8-42 src/…/detect.ts• L24-61 src/…/detect.ts• L11-30 src/…/install.ts• L70-96 src/…/detect.ts• L6-49 src/…/install.ts• L68-108 src/…/system-info.ts• L162-208
Runtime health
Runtime health depends on more than an installed artifact. The connector must receive the event, map the relevant tool correctly, resolve a trusted directory, and return a response that the host honors. The system information path uses bounded version probes and reports unavailable or unsafe-to-inspect agent state rather than changing a running agent's configuration. src/…/system-info.ts• L13-20, src/…/system-info.ts• L162-208, src/…/catalog.ts• L284-317
References: src/…/system-info.ts• L13-20 src/…/system-info.ts• L162-208 src/…/catalog.ts• L284-317
Connector boundaries
Agent-specific code owns only the contract that cannot be shared: event fields, tool names, host callbacks, working-directory fields, session fields, and response shape. The common hook adapter and runtime boundary own input limits, route creation, containment checks, guard evaluation, denial projection, and audit handoff. This boundary keeps new connectors small and prevents agent protocol differences from changing safety behavior.
The detailed connector map and the rules for each host belong in Agent connector implementations. The shared hook sequence and tool-route rules belong in Hook routing and tool adapters. Installation, discovery, generated artifacts, and health checks belong in Integration installation and detection.
Change checklist
When these files or sections are changed, remember to consider these:
- A new or renamed catalog ID must stay aligned with runtime hook metadata, installation metadata, detector status, display names, and audit records.
- A changed agent event field must update the connector's tool route, execution-directory mapping, session lookup, and host response shape as one contract.
- A changed denial or allow response must match the host's rule for serialized output, thrown errors, exit status, and “no decision” behavior.
- A changed execution-directory rule must be checked against both configured policy roots and request-level working-directory fields.
- A new install artifact must have a matching detection method that can distinguish missing, disabled, unreadable, and configured state.
- Hook-config integrations must keep their canonical managed entry aligned across install, uninstall, and drift detection. Changes to matcher, command, type, or timeout can silently narrow protection.
- A new native plugin must preserve the session identity used to connect its decisions to the audit record.
- A changed shared hook shape must preserve safe caller detection for every agent that uses that shape. Ambiguous transcript paths must not select an agent.
- Cursor changes must keep the catalog probe fallback, canonical hook entry, native-plugin checks, Claude Code plugin checks, and duplicate-route warnings aligned.
- DeepSeek Harness changes must keep catalog metadata, web and Desktop profile installation, bundle enablement checks, and session/workdir containment aligned.
- OpenCode changes must keep version checks, plugin installation, plugin detection, both host API generations, shell selection, and runtime activation aligned.
- OpenClaw changes must keep the installed extension files, plugin enablement, runtime load check, and executable-host restrictions aligned.
- Amp changes must keep the personal plugin repository path, managed artifact marker, legacy cleanup, embedded policy state, and local masking-plugin handling aligned.
- Hermes Agent changes must keep the generated plugin files, profile path, enabled-plugin state, and real tool working directory aligned.
- Copilot CLI changes must keep version-gated hook sources, precedence, global disablement, and plugin enablement aligned.
- A changed shared plugin adapter must preserve failed-closed behavior for malformed native events and unexpected guard errors.
- A changed shared agent command template must keep the OpenCode command surface and Pi command prompt aligned with the guidance used by the agent.
Important failure modes
| Trigger | Consequence | Guard |
|---|---|---|
| Hook input is missing, invalid, truncated, or uses an unsupported event name | The agent receives a failed-closed denial and no tool decision is attempted | Bounded input and event checks in src/…/common.ts• L116-145, src/…/hook.ts• L48-57, and src/…/hook.ts• L19-33 |
| Tool input names a missing, invalid, or out-of-scope working directory | The request is denied because the guard cannot prove where it will run | Trusted-root resolution in src/…/intake.ts• L1-60 and host-specific context checks |
| A native event uses an unsupported tool shape, execution host, or workspace | The connector blocks the call or returns no decision when the host contract cannot be proven | Host extraction and route checks in src/…/tool-call.ts• L51-107, src/…/plugin.ts• L73-137, and src/…/tool-call.ts• L67-127 |
| A Cursor hook is duplicated or has the wrong timeout or fail-closed setting | Doctor reports drift, or duplicate routes can check one tool call more than once | Canonical hook writing and drift checks in src/…/install.ts• L54-69, src/…/detect.ts• L29-41 |
| Cursor runs both its hook and a native or imported Claude Code plugin | Each tool call is checked twice and doctor reports the duplicate route | Route detection and duplicate warnings in src/…/detect.ts• L61-109 |
| A Devin CLI or Factory Droid managed entry has a narrowed matcher, wrong type, wrong timeout, or duplicate state | Detection reports drift and the installation path repairs the managed entry without removing other handlers | Canonical entry and drift checks in src/…/pre-tool-use-entries.ts• L17-64, src/…/detect.ts• L20-30, and src/…/detect.ts• L31-47 |
| A DeepSeek Harness event has no valid session directory, command, or requested workdir | The connector denies the call instead of evaluating an untrusted invocation | Session and command checks in src/…/guard.ts• L61-107 |
| A plugin handler throws while processing an event | The host receives a block instead of an unchecked tool call | Failed-closed exception boundary in src/…/plugin-adapter.ts• L57-68 and src/…/common.ts• L280-299 |
| Agent state exists but its configuration cannot be read | Doctor reports the integration as not inspected instead of claiming it is absent or ready | Inspection status model in src/…/doctor-types.ts• L11-24 and state reader in src/…/context.ts• L27-37 |
| A DeepSeek Harness profile contains the package but its bundle is disabled | Detection reports disabled and installation does not claim success | Profile and bundle checks in src/…/detect.ts• L35-87 and src/…/install.ts• L129-145 |
| DeepSeek Harness Desktop is running during a Desktop plugin change | Installation or removal stops before the host can use a partial change | Desktop process check in src/…/install.ts• L67-82 and src/…/install.ts• L101-107 |
| A guard evaluation fails after the invocation is built | The connector returns the host-specific block form and can record the failure stage | Runtime error projection and audit handoff in src/…/runtime.ts• L21-41 and src/…/audit.ts• L76-137 |
| A shared hook payload matches more than one agent home or cannot be safely resolved | The hook does not select an agent from ambiguous evidence | Unique path checks and unknown result in src/…/agent-detection.ts• L24-61 |
| OpenCode is below the supported version, its plugin is inactive, or its plugin cannot load | Installation stops or the host is prevented from running without the safety plugin | Version, activation, and runtime checks in src/…/install.ts• L62-135, src/…/install.ts• L182-201, and src/…/detect.ts• L12-54 |
| OpenCode's configured shell does not match the shell used at spawn time | The v2 plugin stops the action rather than applying the wrong command dialect | Shell option and spawn checks in src/…/v2.ts• L26-73 |
| OpenClaw cannot prove its plugin is enabled or loaded | The integration is reported as disabled or installation fails before runtime use | Plugin config and runtime checks in src/…/detect.ts• L74-107 and src/…/install.ts• L135-159 |
| Amp has no writable personal plugin repository or an unmanaged masking file | Installation stops instead of overwriting another plugin or hiding the managed one | Repository and ownership checks in src/…/install.ts• L78-108 and src/…/install.ts• L128-241 |
| Hermes Agent cannot resolve the session or file-tool directory | The generated plugin blocks the action because path-scoped protection cannot be proven | Plugin-side directory resolution in src/…/artifact.ts• L52-105 |
| Copilot CLI disables all hooks or uses a hook source unsupported by its version | Detection reports disabled or ignores the unsupported source instead of claiming active protection | Version and precedence checks in src/…/detect.ts• L214-313 |
Key files
| File | Why to read it |
|---|---|
| src/…/catalog.ts | Defines the shared identity and lifecycle metadata for every supported agent. |
| src/…/common.ts | Shows the common hook flow from input parsing to guard decision, audit, and host output. |
| src/…/pre-tool-use.ts | Shows the shared pre-tool hook contract and agent response shape. |
| src/…/plugin-adapter.ts | Shows the shared native-plugin boundary from host event to guard decision. |
| src/…/runtime.ts | Shows how integrations enter the common guard and audit path. |
| src/…/invocation.ts | Defines the common representation passed from connectors to safety evaluation. |
| src/…/intake.ts | Shows how integration requests get a trusted execution directory and tool route. |
| src/…/agent-detection.ts | Shows how a shared hook payload is assigned to one caller without guessing. |
| src/…/audit.ts | Shows how agent and session context reach the audit trail. |
| src/…/doctor-types.ts | Defines the status model that separates agent discovery from configuration inspection. |
| src/…/index.ts | Shows how per-agent detection results become an ordered doctor status list. |
| src/…/context.ts | Defines shared state reading and the distinction between missing and unreadable configuration. |
| src/…/choices.ts | Shows how installation availability uses bounded agent CLI probes and configured state. |
| src/…/pre-tool-use-entries.ts | Defines the shared contract for canonical hook entries and drift checks. |
| src/…/system-info.ts | Shows how bounded version and host probes support detection and health reporting. |
| src/…/guard.ts | Illustrates a native connector that maps session, shell, and workdir context into the common guard. |
| src/…/install.ts | Shows profile-aware DeepSeek Harness installation, enablement checks, and safe Desktop handling. |
| src/…/detect.ts | Shows how DeepSeek Harness package and bundle state are detected across profiles. |
| src/…/tool-call.ts | Illustrates a native connector that maps a host event into a command or non-command invocation. |
| src/…/install.ts | Shows the managed Amp personal-plugin installation, embedded policy state, and safe legacy cleanup. |
| src/…/plugin.ts | Illustrates a native plugin with host-specific workspace and execution checks. |
| src/…/install.ts | Shows OpenClaw extension installation and runtime-load verification. |
| src/…/plugin.ts | Shows the OpenCode pre-execution guard and command integration. |
| src/…/v2.ts | Shows the OpenCode v2 hook path and shell consistency check. |
| src/…/install.ts | Shows version-aware OpenCode installation, activation, verification, and managed removal. |
| src/…/detect.ts | Shows how OpenCode plugin presence and runtime failures are detected across config forms. |
| src/…/tool-call.ts | Illustrates a native connector that uses host session and working-directory context. |
| src/…/detect.ts | Shows how Pi package and extension state is detected. |
| src/…/commands.ts | Shows how the agent-facing cc-safety-net command reaches the current Pi conversation. |
| src/…/hook.ts | Illustrates the Devin CLI hook's tool mapping and host denial response. |
| src/…/install.ts | Shows Devin CLI hook configuration installation and managed-entry removal. |
| src/…/detect.ts | Shows how Devin CLI configuration and managed-entry drift are detected. |
| src/…/hook.ts | Illustrates the Factory Droid pre-tool hook route. |
| src/…/install.ts | Shows Factory Droid hook configuration installation, fallback handling, and removal. |
| src/…/detect.ts | Shows how Factory Droid hook configuration and drift are detected. |
| src/…/hook.ts | Illustrates a shared pre-tool-use hook with caller detection and shell routes. |
| src/…/detect.ts | Shows how Claude Code plugin installation and enablement are distinguished, including the plugin route that Cursor may import. |
| src/…/hook.ts | Illustrates the Cursor pre-tool hook route and its workspace mapping. |
| src/…/install.ts | Shows canonical Cursor hook installation and marketplace-plugin cleanup. |
| src/…/detect.ts | Shows how Cursor hook drift, native plugins, imported Claude Code plugins, and duplicate routes are detected. |
| src/…/hook.ts | Illustrates a hook connector that parses host tool input before routing it. |
| src/…/detect.ts | Shows version-aware Copilot CLI hook-source and plugin detection. |
| src/…/artifact.ts | Defines the generated Hermes Agent bridge and its failed-closed tool flow. |
| src/…/hook.ts | Illustrates an agent-specific hook with a request-level working directory. |
| src/…/install.ts | Shows profile-aware managed plugin installation and removal. |
| src/…/detect.ts | Shows how Hermes Agent files and enabled state are checked. |
| src/…/hook.ts | Illustrates a hook that maps workspace paths and tool targets into trusted roots. |
| src/…/hook.ts | Illustrates a hook that rejects truncated input and resolves a workspace root. |
| src/…/install.ts | Shows Grok Build hook file selection and managed entry replacement. |
| src/…/detect.ts | Shows Grok Build hook presence and managed-entry drift detection. |
| src/…/hook.ts | Illustrates a hook connector that applies workspace containment to command calls. |