New:Microsoft Teams Notifications Are Now Available in Socket.Learn more →
Get Started

agentreflex

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

agentreflex

Give your AI agents reflexes — write the logic once, enforce it on every coding agent.

latest
Source
npmnpm
Version
0.4.0
Version published
Weekly downloads
2
Maintainers
1
Weekly downloads
 
Created
Source

agentreflex

agentreflex

Give your AI agents reflexes.
Guardrails and logic that fire before the agent acts — written once, enforced on every coding agent.

MCP gives your agent hands. agentreflex gives it reflexes.

npx agentreflex init

Wires your reflexes into Claude Code, Cursor, Gemini CLI, Copilot CLI, Windsurf, and OpenCode — and compiles them to advisory AGENTS.md for Codex and everything else. Installed globally (npm i -g agentreflex), the command is arx.

A reflex is logic that fires before the agent runs a tool — written once, in a single file you own:

import { defineReflex, deny, pass } from "@agentreflex/core"

export default defineReflex({
  name: "no-force-push",
  onToolCall(ctx) {
    if (ctx.tool === "Bash" && /git push.*--force/.test(ctx.command ?? ""))
      return deny("we agreed: no force-push — open a PR")
    return pass()
  },
})

Beyond single reflexes, arx add installs packs — a product's MCP server (with auth), skills, session hooks, and reflexes as one unit, secrets prompted once and kept user-private. arx doctor verifies each pack's MCP server with a real handshake; arx remove undoes everything.

Commands

arx initscaffold .reflex/ and wire your installed agents
arx add <name | ./path | github: | url>add a reflex or a pack, from the registry or anywhere
arx remove <pack>remove a pack — wiring, files, and stored secrets
arx new <name>scaffold a new reflex
arx install / arx uninstallwire / unwire the dispatcher
arx doctorcapability matrix + live MCP checks for installed packs
arx dev "<cmd>"test a command against your reflexes
  • Website — https://agentreflex.dev
  • Docs — https://docs.agentreflex.dev
  • Source & reflex catalog — https://github.com/agentreflex/agentreflex

MIT

Keywords

ai-agent

FAQs

Package last updated on 13 Jul 2026

Related posts