> ## Documentation Index
> Fetch the complete documentation index at: https://dench.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Human approvals for agent actions

> Require human approval before risky agent actions: request approval, capture an explicit yes or no in chat, and record evidence in Dench.

<Note>
  Approval rule: humans decide. Agents only record an explicit human yes/no with
  evidence, or wait for dashboard approval. Agents never approve their own
  requests.
</Note>

## The loop

<Steps>
  <Step title="Request">
    ```bash theme={null}
    dench approval request "Deploy the new API branch?" \
      --reason "Production deploy changes public behavior." \
      --risk high --json
    ```
  </Step>

  <Step title="Get a human decision">
    Ask in chat, or point them at the approvals page from
    `dench context --json` (`approvalsUrl`).
  </Step>

  <Step title="Record it with evidence">
    <CodeGroup>
      ```bash Approve theme={null}
      dench approval approve <approval_id> --evidence "User said yes in chat" --json
      ```

      ```bash Reject theme={null}
      dench approval reject <approval_id> --evidence "User said no in chat" --json
      ```
    </CodeGroup>
  </Step>
</Steps>

## Always ask before

<CardGroup cols={2}>
  <Card title="Shipping" icon="rocket">
    Merging a PR, deploying, or changing production data.
  </Card>

  <Card title="Money" icon="credit-card">
    Spending money or issuing refunds.
  </Card>

  <Card title="Outbound" icon="paper-plane">
    Sending external email or messages.
  </Card>

  <Card title="Infra & secrets" icon="server">
    Creating or modifying infrastructure, or accessing secrets.
  </Card>
</CardGroup>

<Tip>
  Read-only tool actions don't need approval. Everything that isn't clearly
  read-only does. See [Integrations](/docs/integrations).
</Tip>
