Security Approval Gates

What Are Approval Gates?

Approval Gates implement Human-in-the-Loop (HITL) controls in OpenClaw. They pause agent execution at critical decision points and require explicit human approval before proceeding. This is your last line of defense against unintended or dangerous actions.

When Approval Gates Trigger

Gates activate automatically for operations that meet configurable risk thresholds:

Configuration

Define approval gates in your openclaw.config.json:

{
  "approvalGates": {
    "enabled": true,
    "requireApprovalFor": ["file_delete", "system_modify", "external_api", "db_write"],
    "costThreshold": 0.50,
    "timeoutMinutes": 30,
    "notifyVia": ["discord", "email"],
    "autoApproveReadOnly": true
  }
}

How the Approval Flow Works

  1. The agent identifies an action that requires approval
  2. Execution pauses and a notification is sent to your configured channel (Discord, Slack, email, etc.)
  3. The notification includes: the exact command, why it was triggered, the current context, and potential risks
  4. You review and either Approve, Deny, or Modify the action
  5. The agent resumes or adjusts its approach based on your decision

Best Practices

Prompt Guardian
Protect your AI agent from prompt injection and malicious commands.
Explore Prompt Guardian →