Amp Hooks
Akto Guardrails for Amp provides security validation for AI coding agent interactions. It intercepts tool executions before and after they run, validates against security policies, blocks risky behavior, and reports events to your Akto dashboard.
Key Features
✅ Zero Installation - No standalone apps to install
✅ Transparent Integration - Uses Amp's native hook mechanism
✅ Real-time Tool Blocking - Can block dangerous tool executions before they run
✅ Centralized Monitoring - All events reported to Akto dashboard
✅ Flexible Deployment - Supports Argus and Atlas modes
How It Works
Amp's hook system triggers policy checks at two critical points in every tool execution:
2 Hook Points:
tool:pre-execute— Validates tool use before execution and can block dangerous operationstool:post-execute— Ingests tool execution results for monitoring and audit
Setup Guide
Prerequisites
Amp CLI installed and authenticated — run
amp --versionto verifymacOS or Linux with bash/zsh
Installation Steps
Get the Akto Hook Configuration
Contact support@akto.io to get the Akto guardrail hook configuration for Amp. Akto provides a policy-based amp.hooks configuration tailored to your security requirements.
Configure Hooks in settings.json
Add the Akto-provided hook configuration to ~/.config/amp/settings.json:
Once configured, Akto Guardrails will automatically run its checks on every tool execution. Any malicious or policy-violating events will appear in the Guardrail Activity section of your Akto dashboard.
Resources
Amp Manual — Hooks: https://ampcode.com/manual
Support: support@akto.io
Community: https://www.akto.io/community
Last updated