Agent Guard: Allow-All Claude Code Without Unasked Pushes
Two Claude Code hooks: the agent works freely inside its project, but pushes, PRs and cloud, database or publish commands wait for your approval.
$9
Works with the AI Agents you already use
Agent Guard: Allow-All Claude Code Without Unasked Pushes
Example session with this skill installed
Install agent guard so Claude can work without prompts but never pushes or touches prod without me.
- Read your context and instructions
- Compiled the agent guard
Added agent-guard to ~/.claude/settings.json (PreToolUse for Bash, Write, Edit, MultiEdit, NotebookEdit; PostToolUse for Bash). Tests: 7 passed. Start a new session to load the hooks.
Later, in a session:
git push origin feat/login
agent-guard: this pushes or changes a pull request. Allow?
kubectl apply -f deploy.yaml
agent-guard: this command reaches past the project (cloud, cluster, database, publish or an HTTP write). Allow?
git push --force
Denied. agent-guard: never force-push. Merge the base branch in and push fast-forward.
Connects securely to your tools. The creator never sees your data.
About this skill
Agent Guard lets you give Claude Code broad permissions and still keep control of the calls that leave your machine.
What it does
- Writes outside the project are denied. Symlinks are followed, so a link cannot carry a write out.
- The agent cannot edit
.claude/settings.json, so it cannot switch the guard off. - Force-pushes are denied.
git pushandgh pr create/merge/...ask you first. After you approve 5 pushes in a repo, that repo pushes without asking.- Commands that reach past the project always ask:
kubectl apply,terraform apply,helm install,gcloud,aws,psql,mysql,npm publish,docker push,curl -X POST,gh secret set, migrations and more. - Wrappers such as
env X=1,sudo,sh -c "..."and command chains are unwrapped, sosh -c "git push"still asks. - If the guard itself fails, the call goes to your permission prompt. It never runs without a prompt.
What you get One Node script with no dependencies, a 5-step install that the skill does for you, and 7 tests that you can run after the install.
The core comes from the permission gate in my open-source project Agents of Empire (github.com/wagejs/agents-of-empire). This package makes it a standalone hook, adds the settings protection, and fixes a false force-push match on chained commands.
The guard reads the command text. A script or Makefile target that runs git push or kubectl does not match, so it is a speed bump, not a wall. For a wall, also turn on Claude Code's sandbox. It does not check where Bash writes files; only the file tools (Write, Edit, MultiEdit, NotebookEdit) are confined. Push trust uses the session's working folder, so git -C other-repo push uses the current repo's count. Two sessions that push at the same moment can lose one count.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before any payment.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 4 days ago
Requires
Permissions
File Scopes
No network access. The hook runs git rev-parse to identify the repo.